View Full Version : jQuery - Get original text size

08-13-2009, 05:07 PM

Maybe someone can help me here. I need to get the font size from an element as it is set in the css for a font size detection function I am trying to write.

I have tried using:

$textCurrentSize = parseInt($('#myDiv li a').css('fontSize'));

This sort of works but if I resize the text in the browser it also resizes $textCurrentSize. $textCurrentSize is obvioulsy post-rendered.

What I really need is the original size as set out in the css.

Any ideas anyone?