• AngularJS应用开发思维之1:声明式界面

    时间:2024-01-05 19:58:47

    这篇博客之前承接上一篇:http://www.cnblogs.com/xuema/p/4335180.html重写示例:模板、指令和视图AngularJS最显著的特点是用静态的HTML文档,就可以生成具有动态行为的页面。还是前面的小时钟示例,我们使用AngularJS模板来重写,示例已经嵌入→_→:...

  • Angularjs Post传值后台收不到的原因

    时间:2024-01-05 18:20:11

    如果你给AngularJS的post方法的data参数创一个key-value对象,那传给后台服务的就是JSON字符串,而正常的POST解析是需要像get?后面的那种&name=value这样的字符串,所以后端解析不到参数,简单处理方法,给app加全局http过滤器设置:var app = ...

  • AngularJS -- Bootstrap(启动器)(转载)

    时间:2024-01-05 17:36:37

    AngularJS -- Bootstrap(启动器)点击查看AngularJS系列目录 转载请注明出处:http://www.cnblogs.com/leosx/Bootstrap(初始化)这章介绍了Angular的初始化过程,以及如何在必要的时候,手动进行初始化Angular。Angular &...

  • angularJs 多文件动态上传(删除其中一个文件的时候,要么file没被删除,要么删除了之后,点击事件失效)

    时间:2024-01-05 09:17:09

    <divcacModule.controller('CacScriptEditCtrl', CacScriptEditCtrl); CacScriptEditCtrl.$inject = ['$uibModalInstance', '$scope', '$compile', '$scop...

  • angularjs中下拉框select option默认值

    时间:2024-01-05 08:33:13

    1.问题说明:option ng-repeat多空白项2.解决方案:html:<ion-view hide-nav-bar="true"> <ion-content> <div class="list card"> <div> ...

  • 【回忆1314】第一次用AngularJS

    时间:2024-01-04 19:32:35

    1.创建指令的4种方式(ECMA)var appModule = angular.module('app', []);appModule.directive('hello', function(){ return { /** * E 元素 * C ...

  • [angularjs] 前端路由实现单页跳转

    时间:2024-01-02 17:15:54

    代码:<div ng-app="Home"> <div ui-view></div> <div ng-controller="Index"> <a href="#/one">第一页</a> ...

  • angularjs+nodejs+mongodb三件套

    时间:2024-01-01 17:29:12

    说实话,自己对于web前段的认识并不是太深入,但是因为项目的需要,所以有的时候肯定会需要接触到web前段的知识点。说到web前端想必大家肯定会想到css+js+html,的确web前端的工作,从某总角度来说就是给页面添加必要的一些页面样式来达到美化的效果。我们先来说一说css吧,一种样式语言,它允许...

  • [AngularJS] Javascript scope and AngularJS $scope

    时间:2023-12-31 20:12:09

    Scope resolution of our Angular documents works exactly the same way scope resolution works in plain, old Javascript. The only difference here is that...

  • AngularJS–service(服务)

    时间:2023-12-30 20:52:31

    点击查看AngularJS系列目录 转载请注明出处:http://www.cnblogs.com/leosx/服务Angular的服务也是使用依赖注入(dependency injection (DI))去获取相关对象的实例的。你可以在整个app当中,去共享你的代码。Angular的服务有两点特性:...

  • AngularJS模块

    时间:2023-12-30 14:43:52

    方式一:<body ng-app="myApp"><div ng-controller="myCtrl1"><h1>{{say()}}</h1><h1>{{age}}</h1></div><div ng-con...

  • Ⅴ.AngularJS的点点滴滴-- 资源和过滤

    时间:2023-12-28 23:32:49

    资源ngResource(依赖ngResource模块)<html><script src="http://ajax.googleapis.com/ajax/libs/angularjs/1.2.2/angular.js"></script><script ...

  • Ⅰ.AngularJS的点点滴滴--引导

    时间:2023-12-28 23:28:35

    AngularJS已经被很多人像炒冷饭一样炒过啦,大部分都是直接复制官方文档没有说明一些注意事项,不过什么都要从头开始吧页面引导实例化1.自动实例化<html><script src="http://ajax.googleapis.com/ajax/libs/angularjs/1...

  • 让AngularJS的$http 服务像jQuery.ajax()一样工作

    时间:2023-12-28 23:17:23

    先比较下他们的差别$http的post. 请求默认的content-Type=application/json. 提交的是json对象的字符串化数据,. 后端无法从post中获取,. 跨域请求是复杂请求,会发送OPTIONS的验证请求,成功后才真正发起post请求jQuery.post. 使用的是c...

  • Ⅲ.AngularJS的点点滴滴-- 路由

    时间:2023-12-28 22:58:06

    路由ngRoute (需要依赖ngRoute模块)<html><script src="http://ajax.googleapis.com/ajax/libs/angularjs/1.2.2/angular.js"></script><script src...

  • Ⅱ.AngularJS的点点滴滴--缓存

    时间:2023-12-28 22:56:33

    模板缓存-$templateCache and 缓存工厂 $cacheFactory1.使用script标签<html ng-app><script src="http://ajax.googleapis.com/ajax/libs/angularjs/1.2.2/angular....

  • AngularJs之六(服务)

    时间:2023-12-28 22:55:27

    服务:AngularJS 中,服务是一个函数或对象,可在你的 AngularJS 应用中使用。AngularJS 内建了30 多个服务。最常用的服务:$location  服务,  $http 服务, $timeout 服务,$interval 服务,创建自定义服务一:$location服务。$lo...

  • Ⅶ.AngularJS的点点滴滴-- 事件

    时间:2023-12-28 22:54:43

    事件(和js一样有冒泡和捕获)<html><script src="http://ajax.googleapis.com/ajax/libs/angularjs/1.2.2/angular.js"></script><div ng-controller="p...

  • Ⅵ.AngularJS的点点滴滴-- 指令

    时间:2023-12-28 22:49:58

    指令基本用法<html><script src="http://ajax.googleapis.com/ajax/libs/angularjs/1.2.2/angular.js"></script><div ng-controller="detail">...

  • [AngularJS] AngularJS系列(4) 中级篇之指令

    时间:2023-12-28 21:23:04

    目录API概览使用Angular.UI.Bootstrap自定义指令scopelink我的指令angular中的指令可谓是最复杂的一块但是我们的上传组件就能这么写效果图:API概览先上一段伪代码:angular.module('moduleName', []).directive( '...