- 博客(14)
- 收藏
- 关注
原创 小程序get,post,图片上传 封装
/** * common network methonds * */const app = getApp();const host = app.config.host;const host_img = 'https://upload-z2.qiniup.com';// get const get = (url,params,succ,fail) => { //let...
2018-12-22 17:51:42 1260
原创 jq本地存储
var hiht= localStorage.getItem("hiht");if(hiht == 1){ $('.g-hint').remove()}localStorage.setItem("hiht",1);
2018-09-24 17:30:06 2194
原创 h5 滑动弹框实例
本插件需要引入zepto.min.js,大家自行下载<!DOCTYPE html><html><head> <meta charset="utf-8"> <meta name="viewport" content="width=device-width, initial-scale=1">
2018-08-16 15:40:53 1733
原创 阻止冒泡事件
var clickBt = 0; //定义一个变量$('div').on('click' , function(){ clearTimeout(clickBt); //清除延迟执行 clickBt = setTimeout(function () { price(); }, 10);//延迟执行赋得变量})price function(){ //需要延迟执行的方法}...
2018-07-30 16:52:33 130
原创 css 下拉 小箭头
.menu-down::after {display: inline-block;margin-left: .04rem;width: .07rem;height: .05rem;content: "";background: url(/*图片地址*/) no-repeat;background-size: auto auto;background-size: auto auto;color: ...
2018-07-28 10:56:57 2718
原创 css pc 初始化
@charset "utf-8";/* CSS Document */html { font-size: 100%; -webkit-text-size-adjust: 100%; -ms-text-size-adjust: 100%; }body { _height: 100%; min-width: 1200px; }body, div, p, dl, dt, dd, ul, ol,...
2018-07-28 10:51:15 454
原创 h5 rem字体
@media only screen and (max-width: 1920px), only screen and (max-device-width: 1920px) { html, body { font-size: 512px; } }@media only screen and (max-width: 1440px), only screen...
2018-07-28 10:49:28 184
原创 jq黑色提示弹出框
function messagePop(value){ var str = ''; str += '<div class="pop" style="display:none"><div class="pop-val">'+value+'</div></div>'; $('body').append(
2018-07-28 10:35:25 1179
原创 js tab切换
var messageLi = $(".pw-message-tit li"); //点击tab切换 livar messageUi = $(".js-messages"); //内容显示tab ulfor(var i=0; i<messageLi.length;i++){ messageLi[i].index = i; messageLi[i].onclick = funct...
2018-07-21 10:30:12 610
原创 手机端zepto.js点击滑动显示隐藏
var btn1 = $('.wtw-btn1') //弹框一 function box1(value1,value2){ let str = '<div class="wtw-pop wtw-pop1">'+ '<div class="wtw-pop-bg"></div>'+ '<div class="wtw-pop...
2018-07-21 10:08:42 1769
原创 商品选择,列表排序jq
选择商品筛选//商品点击事件 $(".section-list1").click(function(){ key = $(this).attr("data-id"); $("section-list1").removeClass("section-red"); $(this).addClass("sect...
2018-07-10 16:33:08 970
原创 css 清除浮动
.clearfix::before, .clearfix::after {content: "";height: 0;line-height: 0;display: block;clear: both;}
2018-07-10 10:18:41 108
原创 css 图片高度随宽度变化成正方形
.list-img {width: 100%;position: relative;overflow: hidden;padding-bottom: 100%;//重要属性}.list-img img {width: 100; height: 100%; position: absolute;}
2018-07-10 10:17:12 2334
原创 ajax 手机端滑动分页
//滚动加载更多,tempHeight需要调整 var tempHeight = 1000, timeoutId = 0, headerHeight = $(".header").height(); $(window).on('scroll', function () { clearTimeo...
2018-07-10 10:02:13 2060
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人