- 博客(11)
- 收藏
- 关注
原创 Linux快捷键大全
linux>>ls -l |grep "^-" | wc -l 当前文件夹下的文件个数ctrl + shift + r 输出使用过的相似命令继续ctrl +r 输出上一条使用过的相似命令grep -r -C 10 "error" gulpfile.js 查询文件error上下文ps -ef 查看所有进程ps -ef|grep node 查看node进程kill -9 进程号 杀死这个进
2016-05-21 17:24:32 2934
原创 域名更换为https遇到的问题
页面中不能有任何的http请求 包括cdn,图片,接口请求都必须是https 于是把所有文件都放到本地解决cdn和图片http请求 接口https请求直接请求https,在nginx做转发到本地的nodehttp服务,然后用nodehttpwebserver去请求http接口
2016-05-26 10:29:37 2960
转载 ng-disabled 不起作用的解决办法
不知道这算不算 Angular.js 的一个bug。但搜索一番后找到了一个变通的解决办法。业务需求是这样的, 按钮被点击一次之后就设置为禁用状态, 以阻止多次无效的点击。但现在很多框架都用 或者其他标签来实现 button 效果。我并不是专业的UI, 不知道这样做到底好不好,该怎么样就怎么样呗。在 上面时 ng-disabled 一切正常(因为 支持 disabled ):<button ng
2016-05-26 09:56:41 1347
原创 safari无痕模式localStorage报错
无痕模式应该是禁用了localStorage对象,但是window.localStorage是存在的 但是document.cookie是可以使用的try { localStorage.setItem('isPrivateMode', '1'); localStorage.removeItem('isPrivateMode'); window.isP
2016-05-23 17:49:05 3225
原创 linux服务器部署jenkins,让代码定时自动编译
1 .安装jenkins:google–ubuntu install jenkins 点击第一个搜索结果 在terminal中依次运行看到的shell命令wget -q -O - https://jenkins-ci.org/debian/jenkins-ci.org.key | sudo apt-key add -sudo sh -c 'echo deb http://pkg.jenkins
2016-05-21 17:00:04 3114 3
原创 safari(css,jquery)仿iosNative的actionsheet
先上效果图 html代码:<div id="actionsheet" class="actionsheet hidden"> <div class="actionchoices"> <div class="fieldset"> <div>工作时间:每天9:00-22:00</div> <a
2016-05-15 23:06:18 1262
原创 mobie-web开发6位支付密码验证
第一次想到的方式是直接使用input,加background给出6个输入框,maxlength做限定,会遇到一个问题,letter-spacing没有办法实现大小屏幕适应,因为它不支持%比。 于是开始了第二种方式,就是放6个input,在PC上调试是没有问题的。放到手机上查看问题就出现了,每个输入框focus的时候都会跳跃一下。。于是再次放弃。 最后的解决办法是用div+img画密码,用透明的i
2016-05-12 10:42:22 824
原创 Angularjs输出html
第一种方式 ng-bind-html html<div id="popup" ng-bind-html="popup.content | to_trusted"></div>angularjsapp.filter('to_trusted', ['$sce', function ($sce) { return function (text) { return $sce.trustAs
2016-05-10 22:26:38 1863
原创 Jquery处理url.query
在使用angularjs的时候,获取通过页面路径穿来的参数,只需要使用$location.url这个对象就可以搞定了,但是最近在做支付对接的时候遇到一个问题,页面只需要获取url参数之后做提交表单,这时候如果用angularjs绑定表单的数据,虽然是双向绑定,但是发现提交表单的时候,表单中要绑定的数据并没有加载完毕导致签名错误,然后提交表单setTimeout(func,100)等一秒执行就通过了。
2016-05-10 14:25:01 2039
原创 javascript设计模式--单例模式
单例模式:只允许实例化一次的对象类 这种在基本的编程中可能已经经常的用到,只是不知道是单例模式 比如config.js文件,service.js里都会经常用到:app.factory('payInfo', function($location) { // Might use a resource here that returns a JSON array return { ge
2016-05-07 11:43:20 872
原创 Angularjs的理解和认识
angularjs主要需要理解的模块有 1.AngularJS的双向数据绑定 /tpl下的html文件属于是模板 每个模板都会对应一个controller.js文件 页面通过ng-controller=”controllerName”来绑定controller 通过config.router.js中的 .state(‘app.dashboard-v1’, {
2016-05-06 21:18:16 1738
空空如也
空空如也
TA创建的收藏夹 TA关注的收藏夹
TA关注的人