Login
Sign Up
Home
Tutorials
Microsoft Technologies Tutorials
Java Programming Tutorials
Web Designing Tutorials
Script Programming Tutorials
Database Programming Tutorials
Mobile Technologies Tutorials
Other Programming Tutorials
Examples
Articles
Tools
News
Home
Examples
Angularjs Examples
Angularjs Events Example
AngularJS Events
Angularjs Events Example
Posted On : 13 May 2016
Total Views : 1355
Keywords : Angularjs events ($event) example, How to use events in angularjs with example, Angularjs ng-mouseenter, ng-mouseleave events example
Example
<!DOCTYPE html> <html> <head> <title> AngularJs Events Example </title> <script src="http://ajax.googleapis.com/ajax/libs/angularjs/1.4.8/angular.min.js"></script> <style type="text/css"> .divstyle { padding:20px; border:1px solid black; width:30%; font-weight:bold; background-color:#2b8bc0; color:White; } .mousestyle { background-color:#f2672e; } </style> </head> <body> <div ng-app=""> <h2>AngularJs Events Example</h2> <div class="divstyle" ng-class="{mousestyle: param1}" ng-mouseenter="param1 = true" ng-mouseleave="param1 = false"> Changing Colors on Mouse Hover and Mouse Leave </div> </div> </body> </html>
Click Here to See Output
Output
Share this example
PREVIOUS
AngularJS ng-pattern Email Validation Ex...
NEXT
AngularJS $event Object as Parameter Example
Topics Covered
Search Terms
×
SIGN IN
Thanks to Register with tutlane.com
We sent verification mail to your registered email address to activate your account.
Please check your mail inbox in case if it not there check it in spam / junk folder
Email Address
Password
Lost Password?
Sign In
Dont have an Account yet?
Sign Up
Full Name
Email ID
Password
Re-enter Password
Register
Already have an account?
Sign In
Enter the email you used in your Tutlane profile. We will send your details.
E-mail Address
Submit
An Email has been sent with your account information. Please check your email and login
Already have an account?
Sign In