<!DOCTYPE html>
<
html
lang
=
"en"
>
<
head
>
<
meta
charset
=
"UTF-8"
/>
<
meta
http-equiv
=
"X-UA-Compatible"
content
=
"IE=edge"
/>
<
meta
name
=
"viewport"
content
=
"width=device-width, initial-scale=1.0"
/>
<
link
rel
=
"stylesheet"
href
=
<
link
rel
=
"stylesheet"
href
=
<
title
>GeeksforGeeks | Onsen UI CSS</
title
>
</
head
>
<
body
>
<
center
>
<
h2
style
=
"color:green"
>GeeksforGeeks</
h2
>
<
strong
>
Onsen UI CSS Component Underbar Select input
</
strong
>
<
br
/>
<
h4
>
Choose a type of select with different modifiers:
</
h4
>
<
ons-select
id
=
"mySelectID"
onchange
=
"changeSelectInput(event)"
>
<
option
value
=
"basic"
>Basic</
option
>
<
option
value
=
"underbar"
>Underbar</
option
>
</
ons-select
>
</
center
>
<
script
>
// Sets the value of select input
function changeSelectInput(event) {
document.getElementById('mySelectID')
.removeAttribute('modifier');
if (event.target.value == 'basic' ||
event.target.value == 'underbar') {
document.getElementById('mySelectID').setAttribute(
'modifier', event.target.value);
}
}
</
script
>
</
body
>
</
html
>