angularJs中事件处理
来源:互联网 发布:淘宝退款被拒绝怎么办 编辑:程序博客网 时间:2024/06/07 05:12
<!doctype html><html lang="en"><head> <meta charset="UTF-8"> <script src="angular.min.js"></script></head><body><div ng-app="module" ng-controller="ctrl"> <!--ng-click单击--> <div ng-click="show()">事件1</div> <!--ng-dblclick双击--> <div ng-dblclick="show()">事件2</div> <!--ng-change改变--> <input type="text" ng-change="show()" ng-model="title"> <!--ng-blur失去焦点--> <input type="text" ng-blur="show()" ng-model="title"> <!--ng-focus获取焦点--> <input type="text" ng-focus="show()" ng-model="title"> <!--ng-keydown按下键盘--> <input type="text" ng-keydown="show()" ng-model="title"> <!--ng-keyup抬起键盘--> <input type="text" ng-keyup="show()" ng-model="title"> <!--ng-mousedown鼠标按下--> <input type="text" ng-mousedown="show()" ng-model="title"> <!--ng-mouseup鼠标抬起--> <input type="text" ng-mouseup="show()" ng-model="title"> <!--ng-mouseenter鼠标进入--> <input type="text" ng-mouseenter="show()" ng-model="title"> <!--ng-mouseleave鼠标移开--> <input type="text" ng-mouseleave="show()" ng-model="title"> <!--ng-mousemove鼠标移动--> <input type="text" ng-mousemove="show()" ng-model="title"> {{data}}</div><script> var m = angular.module('module', []); m.controller('ctrl', ['$scope', function ($scope) { $scope.data = ''; $scope.show = function () { $scope.data += '泠泠在路上 '; } }]);</script></body></html>
阅读全文
0 0
- angularJs中事件处理
- AngularJS 控制器中处理DOM事件
- angularJS如何处理事件冒泡
- AngularJS中locationchange、routechange事件
- angularjs事件中html5form自动聚焦失灵
- angularjs中回车键触发某一事件
- AngularJS 事件
- AngularJS 事件
- AngularJS 事件
- AngularJS事件
- AngularJS 事件
- AngularJS 事件
- AngularJS 事件
- AngularJS 事件
- angularJS 事件
- angularJS事件
- AngularJS事件
- c#中事件处理
- 牛腩总结(一)
- SpringMVC异步上传多文件
- 数据库连接到ireport简单示例
- 【龙芯1c库】封装软件延时接口和使用示例
- linux下禁止用户使用密码方式登陆,而只使用密钥方式登陆
- angularJs中事件处理
- 《UNIX网络编程 卷1》 笔记: 广播
- Markdown基本语法
- Maven入门教程(内含实例)
- Error:Execution failed for task ':app:processDebugManifest'. > Manifest merger failed with multiple
- hook_导出表eat
- 主流深度学习开源框架
- 【剑指offer-解题系列(35)】第一个只出现一次的字符
- 03_hibernate5快速入门_JPA的方式