Shawn
Shawn

Reputation: 11401

Is it possible to have <sub>scripts in <option>s in html?

I have a drop down menu full of chemical elements. Is there any way I could format them properly? Ex: H2O

Upvotes: 4

Views: 1995

Answers (1)

mellamokb
mellamokb

Reputation: 56779

You could try using the Unicode subscript characters:

<select>
    <option>H₂O</option>
</select>

Working sample here: http://jsfiddle.net/pZ3mg/

Upvotes: 4

Related Questions