hey all! i was recentley trying to make my images “elastic” to fit all screen resolutions, em’s seemed pretty good. So how big is an em? (eg how many px etc…)
@scottrickmanDec 19.2006 — #If you set your font-size to 62% in your body tag, yes % NOT em this will give everything within that a font-size of (approx) 10px. Then if you want to change the font-size of an element set it to x.x em where x.x is a multiplier i.e. to get 12px equiv. set the font-size to 1.2em. Remember that font-size is inherited from the parent and since em is relative if you nest two elements with the same class attribute the font-size will be applied twice ie. <div class="fontSize1_2em">Text here will be approx. 12px<div class="fontSize1_2em">Text here will be approx 14.4px</div><div class="fontSize1_0em">Text here will be approx 12px</div></div>