Do you have a question? Post it now! No Registration Necessary. Now with pictures!
- Posted on
- Meaning of without attributes
- Jukka K. Korpela
December 15, 2006, 12:07 am
rate this thread
This is pretty theoretical, but it might matter if you convert existing HTML
documents to more modern style, getting rid of <font> markup.
One might expect that just removing all attributes from a <font> tag would
make it dummy, no-op. But I just realized that IE 7 doesn't behave that way.
If I have
<big>foo <font>bar</font> </big>
then bar appears as smaller than bar. Apparently, the browser implies
size="3". Is this acceptable by the specifications?
If I have
<big>foo <font color="red">bar</font> </big>
then foo and bar appear in the same size, i.e. size="3" is _not_ implied by
the browser. This is not consistent at all, of course. Apparently someone
that since <font> alone does not make sense, some attribute needs to be
implied. (Yet <font> could be used for styling and in scripting, or it might
be a holdover after the intentional removal of attributes.)
Jukka K. Korpela ("Yucca")