0

If i try to reproduce this character it shows as a plain simple 2

enter image description here

Someone got an idea how I can reproduce it? it is a 2 that is below the normal textflow and is a bit smaller.

Toskan
  • 13,911
  • 14
  • 95
  • 185

2 Answers2

4

If you need to use subscript in HTML, the element <sub></sub> works fine. There is also <sup></sup> for superscript.

example: H<sub>2</sub>0

reference

13ruce1337
  • 753
  • 1
  • 6
  • 13
  • 1
    just saying: `` elements vertical-align: sub, which actually produces this effect, seems to be different in browser. Since I saw the the CSS reset is setting it to baseline. Just saying – Toskan Apr 19 '14 at 04:18
1

HTML..

<font color="CYAN"><sub><u>2</u></sub></font>

But oh noes! The u tag is deprecated in HTML5. Well, alrighty then.

Time for inline CSS shenanigans.. With a benefit, underline will still work if CSS is disabled thus cater to assistive modes, which is like, a big deal at W3C.

<u style="color:cyan;text-decoration:none;border-bottom: 1px solid cyan;"><sub>2</sub></u>

Looks like it did the job.

  • I assumed the underline was a link. In html the underline is preserved for links. [And in the spirit of html](http://jsfiddle.net/J9gdD/2/) – 13ruce1337 Apr 19 '14 at 03:34
  • W3C site: "The element is redefined in HTML5, to represent text that should be stylistically different from normal text, such as misspelled words or proper nouns in Chinese." – monkeyinshoes Apr 19 '14 at 04:55