By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
438,395 Members | 1,882 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 438,395 IT Pros & Developers. It's quick & easy.

<em> tag wipes out a border

P: n/a
I have a strange problem I can't seem to fix. I've created a content
cell using a table TD, labeled it with a unique ID tag and among other
things, have it display a 1px gray right border. On most pages the box
works fine ... except then I have a paragraph with a long string of
italicized text (EM tag used) in which case the border often
disappears ... but it does not seem to do so consistently ... some
strings of italcized text are fine ... usually I can pinpoint exactly
where the problem.

Have tried a variety of workarounds ... one recent one had me changing
the EM font family from the default verdana, etc. to arial etc. ...
also, creating a P rule with an EM class seemed to work in some cases
as well.

Page samples may be seen at
http://204.50.157.90/seeds/2003/4448.shtm -- with the missing border
and
http://204.50.157.90/seeds/2003/3134.shtm -- where the border is
visible even though there is lots of italicized text.

BTW, I've noticed this problem appears only in IE ... other browsers,
seem to be fine.
Jul 20 '05 #1
Share this Question
Share on Google+
1 Reply


P: n/a
rp********@hotmail.com (Bob Paterson) wrote:
I have a strange problem I can't seem to fix. I've created a content
cell using a table TD, labeled it with a unique ID tag and among other
things, have it display a 1px gray right border. On most pages the box
works fine ... except then I have a paragraph with a long string of
italicized text (EM tag used)
You seem to be using the em element (element, not tag) for things that
are not emphasis. This is wrong.
in which case the border often
disappears ... but it does not seem to do so consistently ... some
strings of italcized text are fine ... usually I can pinpoint exactly
where the problem.

Have tried a variety of workarounds ... one recent one had me changing
the EM font family from the default verdana, etc. to arial etc. ...
also, creating a P rule with an EM class seemed to work in some cases
as well.

Page samples may be seen at
http://204.50.157.90/seeds/2003/4448.shtm -- with the missing border
and
http://204.50.157.90/seeds/2003/3134.shtm -- where the border is
visible even though there is lots of italicized text.

BTW, I've noticed this problem appears only in IE ... other browsers,
seem to be fine.


IE has a bug. It calculates widths, etc. and _then_ changes text to
italics. In many cases this changes the amount of space needed by the
text and causes elements to spill outside their previously calculated
widths.

Steve

--
"My theories appal you, my heresies outrage you,
I never answer letters and you don't like my tie." - The Doctor

Steve Pugh <st***@pugh.net> <http://steve.pugh.net/>
Jul 20 '05 #2

This discussion thread is closed

Replies have been disabled for this discussion.