TECHNOLOGIES
FORUMS
JOBS
BOOKS
EVENTS
INTERVIEWS
Live
MORE
LEARN
Training
CAREER
MEMBERS
VIDEOS
NEWS
BLOGS
Sign Up
Login
No unread comment.
View All Comments
No unread message.
View All Messages
No unread notification.
View All Notifications
C# Corner
Post
An Article
A Blog
A News
A Video
An EBook
An Interview Question
Ask Question
How to use ng-model in select button
Ajay Malik
Aug 05
2016
Code
536
0
0
facebook
twitter
linkedIn
Reddit
WhatsApp
Email
Bookmark
expand
<!DOCTYPE html
>
<
html
>
<
script
src
=
"http://ajax.googleapis.com/ajax/libs/angularjs/1.4.8/angular.min.js"
>
</
script
>
<
body
ng-app
=
""
>
<
form
>
Select a techonoly:
<
select
ng-model
=
"my"
>
<
option
value
=
""
>
<
option
value
=
"py"
>
Python
<
option
value
=
".net"
>
.Net
<
option
value
=
"aj"
>
AngularJs
</
select
>
</
form
>
<
div
ng-switch
=
"my"
>
<
div
ng-switch-when
=
"py"
>
<
h1
>
Python
</
h1
>
<
p
>
General purpose programming language
</
p
>
</
div
>
<
div
ng-switch-when
=
".net"
>
<
h1
>
.net
</
h1
>
<
p
>
Microsoft framework for c#
</
p
>
</
div
>
<
div
ng-switch-when
=
"aj"
>
<
h1
>
AngularJs
</
h1
>
<
p
>
Javascript framework from google
</
p
>
</
div
>
</
div
>
</
body
>
</
html
>
AngularJs
selectbutton