Want to protect your cyber security and still get fast solutions? Ask a secure question today.Go Premium

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 470
  • Last Modified:

First toggling - slideToggle() - on page load

I am using slidetoggle() with jquery to hide and show my menus on click. If you go to ryanbent.com you will see the top links, the items: contact, portfolio, and about, have slidetoggle. If you notice on page load, they are all DISPLAYED.

Check this by adding display:block to #fuzz, the gray light out.

So I thought this would work:
$('#about-pull,#portfolio-pull,#contact-pull').slideToggle();

I have this within document.ready and it doesnt run, but if I use FireBug and run it via Scirpt, it works fine.

Any ideas?

Thanks,

Ryan
0
catonthecouchproductions
Asked:
catonthecouchproductions
1 Solution
 
David H.H.LeeCommented:
Hi Ryan,
You can use hide() method instead of slideToggle() in page load.
eg:
$('#about-pull,#portfolio-pull,#contact-pull').hide();

Check this link for further details:
http://docs.jquery.com/Effects/hide
0
 
catonthecouchproductionsAuthor Commented:
Ahhh! Worked perfect.. thank you!

Ryan
0

Featured Post

Free Tool: Site Down Detector

Helpful to verify reports of your own downtime, or to double check a downed website you are trying to access.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now