HighDots Forums  

Re: <span style="display: none;"> not working in a table...

Cascading Style Sheets Layout/presentation on the WWW (comp.infosystems.www.authoring.stylesheets)


Discuss Re: <span style="display: none;"> not working in a table... in the Cascading Style Sheets forum.



Reply
 
Thread Tools Display Modes
  #1  
Old   
David Dorward
 
Posts: n/a

Default Re: <span style="display: none;"> not working in a table... - 01-08-2008 , 02:33 AM






On Jan 8, 7:14*am, jodleren <sonn... (AT) hot (DOT) ee> wrote:
Quote:
I have the code below. I have used something similar before (also in
tables), but this time the span in visible all the time - the idea is
to show the <tr> row only when needed.
What do I do wrong?
You are trying to make a span element a child of a table element or
tbody element (only caption, col, colgroup, tbody, thead and tfoot
elements may be children of a table element[1], and only tr elements
may be children of tbody elements.

You are also trying to make tr elements children of span elements, and
only tbody, thead or tfoot elements may be parent elements of tr
elements.

Basically, you didn't validate and it doesn't work.

Also, trying to have an element display: inline within a table tends
to break the table layout model (which expects things which render
like tables to be made up of elements with display values which use
the table-* properties.

I could suggest playing with the display value of the tr element and
forgetting about using extra markup at all, but it looks rather like
you are using tables for layout so read http://www.hotdesign.com/seybold/
instead.

And href="#"? Please use sensible fallbacks for your JavaScript. "Call
hideInlineItem, or, if JS is not available or the function fails, go
to the top of the page" probably doesn't qualify.
http://www.wait-till-i.com/2007/11/1...ve-javascript/
is a worthwhile read.

[1] although the start and end tags of tbody elements are optional, so
it looks like tr elements are allowed there

--
David Dorward
http://dorward.me.uk/
http://blog.dorward.me.uk/


Reply With Quote
Reply




Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off



Powered by vBulletin Version 3.5.4
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.