Jump to content

Menu that holds state


seventheyejosh

Recommended Posts

Hello all i'm needing to make a menu that holds its state throughout the page clicks.

 

So all options start with a class of closed. when the page is changed tho i need any of the ones that were open to be auto assigned the open class when the page loads.

 

I posted here cause i figured you guys might now of a jquery menu system that'll help me. Or if you can give me a really simple javascript chunk.

 

all i need is onclick run a function that makes a cookie called, say menu-id_of_item then when the page loads just do like an if isset... class = open. i dont need the actual value of the cookie i dont think. just if its set.

Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.