Prev Demo
AngularJS
>
Switch In Angularjs
Next Demo
Write code here
J
|
B
|
A
<!DOCTYPE html> <html> <head> <title>Demo</title> <script src="https://ajax.googleapis.com/ajax/libs/angularjs/1.3.14/angular.min.js"></script> </head> <body> <div ng-app> <select ng-model="dropSelection" ng-init="dropSelection = 'Select'"> <option value="ASP">ASP</option> <option value="JSP">JSP</option> <option value="PHP">PHP</option> <option value="Select">Select</option> </select> <div ng-switch="dropSelection"> <div ng-switch-when="ASP">ASP is a server side scripting language developed by Microsoft</div> <div ng-switch-when="JSP">JSP is a server side scripting language developed for Java</div> <div ng-switch-when="PHP">PHP is a open source server side scripting language</div> <div ng-switch-default>Please select from drop down</div> </div> </div> </body> </html>
Note: We DO NOT save your trial code in our database.
Output