On 18 Jul., 16:12, matt <[EMAIL PROTECTED]> wrote:
> Hi, im currently styling a menu using a java script effect which hides
> the nested submenus on load, and also shows/hides them on mouseover.
> It is working in firefox, using  ...
>
> var ul = $("nav").getElementsByTagName("ul")[0];
>
> var lis = ul.immediateDescendants();
>
> I then loop through lis to initially hide all the submenus. This works
> fine in firefox, but not in IE. The sub menus are still visible when
> the page loads?!
>
> Any ideas?

Assuming you only have one ul element within #nav (or, the same
behavior should be applied to all ul's within #nav), you could do
this:

$$('#nav ul > *').invoke('hide');


--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "Ruby 
on Rails: Spinoffs" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at 
http://groups.google.com/group/rubyonrails-spinoffs?hl=en
-~----------~----~----~----~------~----~------~--~---

Reply via email to