摘要: var MyMar=setInterval(Marquee,speed); scroll_div.onmouseover=function() {clearInterval(MyMar);} scroll_div.onmouseout=function() {MyMar=setInterval(Ma 阅读全文
posted @ 2017-11-09 11:40 欧辰0312 阅读(2682) 评论(0) 推荐(0) 编辑
摘要: <script type="text/javascript"> var u = navigator.userAgent; var isAndroid = u.indexOf('Android') > -1 || u.indexOf('Adr') > -1; //android终端 var isiOS 阅读全文
posted @ 2017-11-07 14:48 欧辰0312 阅读(253) 评论(0) 推荐(0) 编辑
摘要: 用for循环或者forEach遍历数组的话,在方法体内部splice都得不到正确的结果,解决方法是使用逆向循环 方法一,用 filter 方法二,用逆向循环 阅读全文
posted @ 2017-11-07 11:13 欧辰0312 阅读(23120) 评论(1) 推荐(3) 编辑
摘要: function getUrlParam(key) { // 获取参数 var url = window.location.search; // 正则筛选地址栏 var reg = new RegExp("(^|&)" + key + "=([^&]*)(&|$)"); ... 阅读全文
posted @ 2017-10-13 15:54 欧辰0312 阅读(191) 评论(0) 推荐(0) 编辑
摘要: picker地址: http://ustbhuangyi.github.io/picker/ 阅读全文
posted @ 2017-09-29 17:49 欧辰0312 阅读(144) 评论(0) 推荐(0) 编辑
摘要: var num = finalnum = tempnum = 0; var lis = $(".star-box span"); //num:传入点亮星星的个数 //finalnum:最终点亮星星的个数 //tempnum:一个中间值 function fnShow(num) { finaln... 阅读全文
posted @ 2017-09-21 14:27 欧辰0312 阅读(231) 评论(0) 推荐(0) 编辑
摘要: <div class="upload-wrap"> <!--<div>添加图片(限4张)</div>--> <ul class="upload am-cf am-gallery" data-am-widget="gallery" data-am-gallery="{ pureview: true } 阅读全文
posted @ 2017-09-21 14:22 欧辰0312 阅读(150) 评论(0) 推荐(0) 编辑
摘要: //上传头像 $('.j-file').on('change', function(e) { if(!window.FileReader) return; var files = e.target.files; var content = ''; ... 阅读全文
posted @ 2017-09-18 16:27 欧辰0312 阅读(112) 评论(0) 推荐(0) 编辑
摘要: 辅助方法(解决模板不能访问全局对象的问题) 使用 template.helper(name, callback) 注册公用辅助方法,例如一个访问全局变量jQuery的方法: template.helper('getJquery', function () { return $; }); templa 阅读全文
posted @ 2017-08-29 14:17 欧辰0312 阅读(573) 评论(0) 推荐(0) 编辑
摘要: 微信分享使用微信默认分享,但我们可以设置分享的内容和分享到那个平台 阅读全文
posted @ 2017-08-15 16:30 欧辰0312 阅读(372) 评论(0) 推荐(0) 编辑