Re: How do you hide controls and the whitespace?

Tech-Archive recommends: Repair Windows Errors & Optimize Windows Performance



Brian Kitt wrote:
> I have a very long table, about 200 rows. I am trying to make
> buttons that can alternately hide and reveal sections of the table.
> It's easy enough to hide and reveal sections with the
> visibility=hidden, but when the section is hidden, all of the area it
> took up is now whitespace. How do I hide rows of the table and not
> have the area become whitespace. In other words, how do I compress
> the rows to basically just disappear.

I think the JS el.style.display="none" will remove the blank space

el is defined in JS as the relevant element, e.g.
el=document.getElementById('rowname') where rowname is the id of the row or
it could even be a span or div
--
Cheers,
Trevor L.
Website: http://tandcl.homemail.com.au


.



Relevant Pages

  • Re: Different number of children in IE, Firefox and Opera
    ... var output = cell.childNodes.length; ... Isn't the cell at supposed to have 2 children only, div first ... If you remove all the whitespace in between the divs and tds ... Firefox seems to interpret the whitespace as ...
    (comp.lang.javascript)
  • Re: Unexpected whitespace following IMG tag
    ... There is a newline there; that whitespace becomes folded into a single space in the output. ... So, to remove the space, you need to have 0 whitespace between the img and div tags. ...
    (comp.infosystems.www.authoring.stylesheets)
  • Re: Unexpected whitespace following IMG tag
    ... There is a newline there; that whitespace becomes folded into a single space in the output. ... So, to remove the space, you need to have 0 whitespace between the img and div tags. ...
    (comp.infosystems.www.authoring.stylesheets)
  • Re:
    ... and twiddle with the whitespace around your list. ... Is there a way around this?Wrap it in a DIV and set the DIV's style to 'overflow: scroll' and then give ...
    (microsoft.public.dotnet.framework.aspnet)
  • Re: Div Not Filling Page?
    ... > I have a DIV which I want to completely go from one side of the page to ... with not whitespace or margins. ... Sonhos vem. ...
    (alt.html)