[thelist] how to unset a css pseudo-class by javascript ?

ben morrison morrison.ben at gmail.com
Fri Jun 30 08:56:31 CDT 2006


On 6/30/06, Olivier Percebois-Garve <percebois at gmail.com> wrote:
> "That is a very cumbersome approach. I normally tend just to apply a
> class to the UL when the page is ready that hides all the LIs...
>
> .dynamic ul li(display:none;)
>
> That way I don't have to loop through the lot, but simply let the
> browser CSS engine do that."
>
> If you do that, and javascript is off and css on, then the tree remains collapsed,
> and it becomes obtrusive, isn't it ?


"apply a class to the UL when the page is ready"

Use JS to change the CSS style when the page has loaded.

Ben



More information about the thelist mailing list