09 2014 档案
創建HTTP 服務器
摘要:1 var http = require('http'); 2 var fs = require('fs'); 3 var server = http.createServer(function(req, res) { 4 if (req.url !== "/favicon.ico... 阅读全文
posted @ 2014-09-25 23:26 ทดสอบ 阅读(232) 评论(0) 推荐(0) 编辑
angular 页面加载时可以调用 函数处理
摘要:转载于作者:海底苍鹰地址:http://blog.51yip.com/jsjquery/1599.html我希望页面加载的时候,我能马上处理页面的数据,如请求API ....所以这样设置 在某个页面的控制器中 监听页面loadphonecatControllers.controller('regis... 阅读全文
posted @ 2014-09-22 17:05 ทดสอบ 阅读(621) 评论(0) 推荐(0) 编辑
angular factory Services provider 自定义服务 工厂
摘要:转载于作者:海底苍鹰地址:http://blog.51yip.com/jsjquery/1602.html1.在app.js 中声明了模块的依赖1 var phonecatApp = angular.module('phonecatApp', [2 'ngRoute',3 'phonecatCont... 阅读全文
posted @ 2014-09-22 14:45 ทดสอบ 阅读(421) 评论(0) 推荐(0) 编辑
ionic goto other page or alert
摘要:有时候需要 调试,这是就需要alert 的...可惜的是我不会angular 所以记录一下.controller('mainctr', function($scope, $window) { $window.alert('xxxxx');})只需要 $window 就可以了;跳转页面的时候,$st... 阅读全文
posted @ 2014-09-19 18:19 ทดสอบ 阅读(737) 评论(0) 推荐(0) 编辑
ionic cordova plugin simple demo
摘要:要用cordova plugin 的话还是需要设置一下的1. 下载 ng-cordova.jsdownload the zip file here2. 在index.html 中引用 (cordova.js 之前引进)如下: 3.在你的angular.module 声明 如下angul... 阅读全文
posted @ 2014-09-19 14:39 ทดสอบ 阅读(1066) 评论(0) 推荐(0) 编辑
ionic phonegap translate language demo
摘要:中英文转换,经常用到;而ionic 则是通过angular js 来实现;用到了http://www.ng-newsletter.com/posts/angular-translate.html 中的angular-translate.min.js 让translate language 变得很简单... 阅读全文
posted @ 2014-09-19 10:33 ทดสอบ 阅读(416) 评论(0) 推荐(0) 编辑


点击右上角即可分享
微信分享提示