Current location: Hot Scripts Forums » General Web Coding » JavaScript » Vraag van Noob -> Cookies in JavaScript


Vraag van Noob -> Cookies in JavaScript

Reply
  #1 (permalink)  
Old 07-30-05, 07:35 AM
Muiter Muiter is offline
New Member
 
Join Date: Jul 2005
Posts: 1
Thanks: 0
Thanked 0 Times in 0 Posts
Vraag van Noob -> Cookies in JavaScript

I'm using this script:
Code:
<script type="text/javascript"> 
<!-- 
function menu_toggle(id) 
{ 
    if( document.getElementById(id).style.display == '') 
   { 
       document.getElementById(id).style.display = 'none'; 
   } 
   else 
   { 
       document.getElementById(id).style.display = ''; 
   } 
   return true; 
}  

--> 

</script>   

<a href="#" onclick="menu_toggle('div55');">open/sluit</a> 
<div id="div55" style="display: menu;"> 
My menu 
</div>
Works great but when going to another page the menu is back. How can I store the action (open or close) in a cookie, standard the menu is open.
Reply With Quote
  #2 (permalink)  
Old 08-02-05, 04:17 AM
NeverMind's Avatar
NeverMind NeverMind is offline
Community VIP
 
Join Date: Aug 2003
Location: K.S.A
Posts: 2,257
Thanks: 0
Thanked 2 Times in 1 Post
__________________
PHPSimplicity
We don't need a reason to help people - Zidane [FF9]
Reply With Quote
Reply

Bookmarks


Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
 
Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

Forum Jump

Similar Threads
Thread Thread Starter Forum Replies Last Post
Can't seem to get the cookies to the cookie_jar benny666 Perl 1 10-28-03 04:54 AM


All times are GMT -5. The time now is 10:53 PM.
vBulletin® Copyright ©2000 - 2012, Jelsoft Enterprises Ltd.