prgrm prgrm -3 years ago 51
CSS Question

Hidden divs make my site too long

I have something like this:

<div id="content" style="visibility: hidden;">
<!-- 500 lines of HTML --->
</div>


This div contain divs that are shown via Javascript. The problem is that it makes my site's height too big even if nothing is shown.

I know I could just add the divs to be generated in the Javascript file, but I wonder if there is a CSS solution, since I like to have the "skeleton" in the HTML instead of the Javascript.

Answer Source

style="display: none" in the css

Recommended from our users: Dynamic Network Monitoring from WhatsUp Gold from IPSwitch. Free Download