• AngularJS进阶(三)HTML:让表单、文本框只读,不可编辑的方法

    时间:2024-01-07 10:39:05

    HTML:让表单、文本框只读,不可编辑的方法有时候,我们希望表单中的文本框是只读的,让用户不能修改其中的信息,如使<input type="text" name="input1" value="中国"> 的内容,"中国"两个字不可以修改。实现的方式归纳一下,有如下几种。方法1: onfo...

  • angularjs入门(二)

    时间:2024-01-07 09:42:15

    angularJs是一个mvc模式,m-model-->当前视图中可用的数据,v-view--> HTML。c-controller-->即 JavaScript 函数,可以添加或修改属性接下来的就是按照这个模式来开展项目的学习。 <div ng-app="myApp"...

  • 开启AngularJS 1.X的学习之路(1)

    时间:2024-01-07 08:26:47

    概念(1)AngularJS 应用AngularJS 模块(Module) 定义了 AngularJS 应用。AngularJS 控制器(Controller) 用于控制 AngularJS 应用。ng-app指令定义了应用, ng-controller 定义了控制器。eg:<div ng-a...

  • 使用AngularJS开发下一代Web应用

    时间:2024-01-05 22:04:44

    原版的:https://github.com/edagarli/AngularJSWeb来源书:https://github.com/shyamseshadri/angularjs-book版权声明:本文博客原创文章,博客,未经同意,不得转载。

  • 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....