摘要: cookie封装的方法 取数据 参数数据 删除数据 阅读全文
posted @ 2016-11-29 21:57 csw123 阅读(90) 评论(0) 推荐(0) 编辑
摘要: ng-click="deleteT(ele);$event.stopPropagation()" 阅读全文
posted @ 2017-06-09 10:49 csw123 阅读(1848) 评论(0) 推荐(0) 编辑
摘要: showdaytext : function(time){ var showday = { "1" : "一天后开始", "2" : "两天后开始", "3" : "三天后开始", }; var upday = new Date(time).getTime() - new Date().getTim 阅读全文
posted @ 2017-05-18 17:38 csw123 阅读(140) 评论(0) 推荐(0) 编辑
摘要: //模拟ie不兼容问题 .directive('inputs', ['$compile', function($compile){ return { restrict: 'ECMA', scope: {}, link: function(scope, ele, attr) { console.log 阅读全文
posted @ 2017-04-13 13:59 csw123 阅读(1657) 评论(0) 推荐(0) 编辑
摘要: angular.module('app',[]) .controller('ctrl',function ($http,$scope){ //ctrl控制器,名称作用的范围 html中ng-controoler='ctrl' var page=1; //读取的页数 f=false //判断是否读取内 阅读全文
posted @ 2016-12-17 11:15 csw123 阅读(290) 评论(0) 推荐(0) 编辑
摘要: //jsonp的封装函数 function jsonp(url,parmter,callback){ //创建script标签 var script=document.createElement('script'); //拼接字符串 randomkey='cdf'+new Date().getTim 阅读全文
posted @ 2016-12-01 11:05 csw123 阅读(637) 评论(0) 推荐(0) 编辑
摘要: HTML5中增加了两种全新数据存储方式:Web Storage和Web SQL Database. 前者可用于临时或永久保存客户端的少量数据;后者是客户端本地化的一套数据库系统,可将大量数据保存在客户端,无需与服务端交互。极大的减轻了服务端的呀,加快了页面浏览的速度。 Web Storage分为会话 阅读全文
posted @ 2016-11-30 19:23 csw123 阅读(932) 评论(0) 推荐(0) 编辑
摘要: sessionStorage 和 localStorage 是HTML5 Web Storage API 提供的,可以方便的在web请求之间保存数据。有了本地数据,就可以避免数据在浏览器和服务器间不必要地来回传递。 sessionStorage、localStorage、cookie都是在浏览器端存 阅读全文
posted @ 2016-11-30 18:55 csw123 阅读(201) 评论(0) 推荐(0) 编辑
摘要: !DOCTYPE html><html> <head> <meta charset="utf-8"> <title></title> </head> <body> </body> <script type="text/javascript"> // 使用sessitonStrolage进行存储 // 阅读全文
posted @ 2016-11-29 22:06 csw123 阅读(602) 评论(0) 推荐(0) 编辑
摘要: <!DOCTYPE html><html> <head> <meta charset="utf-8"> <title>requestAnimationFrames</title> <style media="screen"> canvas { box-shadow: 0 0 10px black; 阅读全文
posted @ 2016-11-29 22:00 csw123 阅读(128) 评论(0) 推荐(0) 编辑