For a long time I've been using
body {font-size:62.5%;}
in CSS documents since it's supposed to make 1em
equal 10px
. However, I recently noticed that this isn't the case for me in Internet Explorer. So instead I tried the code:
html {font-size:100%}
body {font-size:10px}
Now this works like a charm for me. My question is:
What's the drawback of this solution since I can't find anyone else using it?
To clarify: I later specify all my font-sizes, widths, heights and so forth in em
. It's just in the body I use 10px
instead of 62.5%
.
See Question&Answers more detail:
os 与恶龙缠斗过久,自身亦成为恶龙;凝视深渊过久,深渊将回以凝视…