文章分类 -  2016前端

摘要:String.prototype.trim=function(){returnthis.replace(/(^\s*)|(\s*$)/g,"");} 阅读全文

posted @ 2016-12-13 17:04 发飙的木鱼 阅读(43) 评论(0) 推荐(0)

摘要:html部分 <div class="search searchPlace"> <input class="searchPlace" id="SearchName" onkeyup="SearchName(event)" type="text" placeholder="输入查找的接口关键字" va 阅读全文

posted @ 2016-11-18 15:23 发飙的木鱼 阅读(140) 评论(0) 推荐(0)

摘要:0、只能输入正整数 <input onkeyup="if(this.value.length==1){this.value=this.value.replace(/[^1-9]/g,'')}else{this.value=this.value.replace(/\D/g,'')}" onafterp 阅读全文

posted @ 2016-11-17 09:30 发飙的木鱼 阅读(101) 评论(0) 推荐(0)

摘要:function browserRedirect() { var sUserAgent= navigator.userAgent.toLowerCase(); var bIsIpad= sUserAgent.match(/ipad/i) == "ipad"; var bIsIphoneOs= sUs 阅读全文

posted @ 2016-11-15 16:45 发飙的木鱼 阅读(64) 评论(0) 推荐(0)

摘要:js部分 //历史事记出现在可视区事件 var isAct = true; var itemHeight,vh,yh; $(window).scroll(function(){ itemHeight = parseInt($(".historyUl").outerHeight(true));//内容 阅读全文

posted @ 2016-11-03 17:04 发飙的木鱼 阅读(101) 评论(0) 推荐(0)

摘要:html部分 转载滴 <form id="importBookForm" action="uploadReadBook.action" encType="multipart/form-data" method="post" target="hidden_frame"> <input id="myFi 阅读全文

posted @ 2016-10-25 11:51 发飙的木鱼 阅读(273) 评论(0) 推荐(0)

摘要:var req = createXMLHTTPRequest(); if(req){ var url=SSlocalhostPaht + "/api/getInterfacePackageList?" + new Date().getTime(); req.open("POST", url, tru 阅读全文

posted @ 2016-10-20 11:42 发飙的木鱼 阅读(29) 评论(0) 推荐(0)

摘要://json2.js开始 使Json兼容ie6 7 8 var JSON;if (!JSON) { JSON = {};}(function () { 'use strict'; function f(n) { return n < 10 ? '0' + n : n; } if (typeof Da 阅读全文

posted @ 2016-10-19 15:16 发飙的木鱼 阅读(443) 评论(0) 推荐(0)

摘要:js 部分 /** * * 首页幻灯 * Mandy */ $(function() { if($("#focus ul li").length>1){ bannerAct("focus",5000); } if($("#focus2 ul li").length>0){ $(".rightActB 阅读全文

posted @ 2016-10-19 14:40 发飙的木鱼 阅读(67) 评论(0) 推荐(0)

摘要:判断内容是否在可视区$(window).scroll(function(){ var itemHeight = parseInt($(".historyUl").outerHeight(true));//内容区域的高度 var vh = parseInt($(window).height());// 阅读全文

posted @ 2016-10-19 14:36 发飙的木鱼 阅读(110) 评论(0) 推荐(0)

摘要:转载滴http://www.2cto.com/kf/201402/281430.html HTML5中的FileReader对象: FileReader对象主要是把文件读入内存中,并且读取文件中数据。目前为止,firefox3.6+ chrome6+ Safari5.2+ Opera11+及IE10 阅读全文

posted @ 2016-10-14 18:27 发飙的木鱼 阅读(387) 评论(0) 推荐(0)