|
-
Nov 3rd, 2006, 02:37 PM
#1
Thread Starter
New Member
CSS: Hide the TR or the TD?
When the page is displayed on the monitor I want to have one header. When the page is printed I want to replace that with a simple logo. I've used display: none before. The way the page is laid out I can have two rows, one with the first header and one with the logo. Should I attach display: none to the TR or to the TD? (Yes I know, use a div. But work with me on this one.)
-
Nov 6th, 2006, 03:57 AM
#2
Re: CSS: Hide the TR or the TD?
Use a DIV. I've seen Firefox do very weird things if you apply display:none to any table sub-elements.
All the buzzt
 CornedBee
"Writing specifications is like writing a novel. Writing code is like writing poetry."
- Anonymous, published by Raymond Chen
Don't PM me with your problems, I scan most of the forums daily. If you do PM me, I will not answer your question.
-
Nov 6th, 2006, 10:11 AM
#3
Thread Starter
New Member
Re: CSS: Hide the TR or the TD?
Weird cool or weird OMG? Either way, this looks like the perfect excuse to stop supporting those few clients who are still using Win95 and IE4 (seriously) and get them to upgrade to IE5. Thanks CornedBee.
-
Nov 6th, 2006, 10:20 AM
#4
Re: CSS: Hide the TR or the TD?
If it is a header then you should use a header tag, possibly H1 Because, well, it is a header. You can style H1 just like you can style a DIV; only difference is that H1 describes better what is the content actually in question. DIV and SPAN are general purpose, to be used when you can't use anything else.
-
Nov 6th, 2006, 11:09 AM
#5
Re: CSS: Hide the TR or the TD?
 Originally Posted by VBCasey
Weird cool or weird OMG?
Weird as in it removes the content, but the space is still taken up. Show the row and it will be below its old place, hide it and that space, too, is blank and unused. In other words, the more often you repeat, the more space is taken up.
All the buzzt
 CornedBee
"Writing specifications is like writing a novel. Writing code is like writing poetry."
- Anonymous, published by Raymond Chen
Don't PM me with your problems, I scan most of the forums daily. If you do PM me, I will not answer your question.
-
Nov 6th, 2006, 12:35 PM
#6
Re: CSS: Hide the TR or the TD?
Corned Bee: that doesn't always happen. Although I've seen that effect with Opera, not Firefox. But probably a different rendering bug, done differently. My tactic was just to move rows out of the screen with position : absolute;
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
|
Click Here to Expand Forum to Full Width
|