随笔分类 -  angular

angular
摘要:这是一个最简单的angularjs的例子,关于数据绑定的,大家可以执行一下,看看效果 关于数据双向绑定,有时候不需要实时同步,比如当输入框失去焦点的时候才去更新div里面的内容,这里可以用上ng-model-options属性来解决,将上面的代码稍做修改: 或者改为每隔1秒来更新: 阅读全文
posted @ 2016-02-01 00:43 魔豆 阅读(456) 评论(0) 推荐(0)
摘要:当然了,直接用Eclipse开发,完全没问题。我只是需要加个智能感知,安装一个Eclipse插件。 Eclipse菜单-》Help-》Eclipse Marketplace 安装完以后,项目并不能直接支持argularjs语法的智能感知,需要通过右键项目-》Configure-》Convert to 阅读全文
posted @ 2016-02-01 00:13 魔豆 阅读(3017) 评论(1) 推荐(0)
摘要:<html ng-app="myApp"> <head> <title>angularjs-ajax</title> <script type="text/javascript" src="js/angular149/angular.min.js"></script> </head> <body n 阅读全文
posted @ 2016-01-31 13:10 魔豆 阅读(512) 评论(0) 推荐(0)
摘要:<%@ page language="java" contentType="text/html; charset=UTF-8" pageEncoding="UTF-8"%> <html ng-app="myApp"> <head> <title>angularjs-cookie</title> <s 阅读全文
posted @ 2016-01-31 12:49 魔豆 阅读(732) 评论(0) 推荐(0)
摘要:Sample.html <!DOCTYPE html> <html ng-app="myApp"> <head> <title>form</title> <script type="text/javascript" src="js/angular.min.js"></script> </head> 阅读全文
posted @ 2016-01-30 23:13 魔豆 阅读(1818) 评论(0) 推荐(0)
摘要:<!DOCTYPE html> <html ng-app="myApp"> <head> <title>angularjs-setValue</title> </head> <body ng-controller="body"> <input type="text" name="input1" ng 阅读全文
posted @ 2016-01-30 15:12 魔豆 阅读(1712) 评论(0) 推荐(0)
摘要:<!DOCTYPE html> <html ng-app="myApp"> <head> <title>angularjs-validate</title> <script type="text/javascript" src="js/angular.min.js"></script> </head 阅读全文
posted @ 2016-01-30 15:01 魔豆 阅读(268) 评论(0) 推荐(0)
摘要:<!DOCTYPE html> <html ng-app="myApp"> <head> <title>angularjs-setValue</title> </head> <body ng-controller="body"> <input type="text" name="input1" ng 阅读全文
posted @ 2016-01-30 14:38 魔豆 阅读(1433) 评论(0) 推荐(0)
摘要:<!DOCTYPE html> <html ng-app="myApp"> <head> <title>angularjs-focus</title> </head> <body> <input type="text" set-Focus=""> <script type="text/javascr 阅读全文
posted @ 2016-01-30 14:05 魔豆 阅读(1225) 评论(0) 推荐(0)