|
Posted by Jim Moe on 08/26/07 17:45
lhjayunaz@gmail.com wrote:
> hi, is it possible in any way, to read or determine absolute pixel
> width size of contents within a <div> tag?
>
> so like <div>what is pixel wXX size of this text?</div>
>
For HTML, no.
It would have to be a client-side function since a div normally expands
to the width of its container. If it is floated, then it shrinkwraps the
text, probably. In either case it depends on the client's current setup:
the width of the viewport, the metrics of the font set.
What is your application that needs to know this information?
--
jmm (hyphen) list (at) sohnen-moe (dot) com
(Remove .AXSPAMGN for email)
Navigation:
[Reply to this message]
|