Current location: Hot Scripts Forums » General Web Coding » JavaScript » click then open menu


click then open menu

Reply
  #1 (permalink)  
Old 11-07-04, 06:05 PM
ramez ramez is offline
Newbie Coder
 
Join Date: Jul 2003
Posts: 42
Thanks: 0
Thanked 0 Times in 0 Posts
click then open menu

hi guys...


i want to see can JavaScript do this:

i have a graph menu it's first colsed when the user click an open image it's open the menu ...

lets make it clear

I have a menu in a table it's graph menu ...
in the left corner there i a cicle when the user click this cicle

it's open the image when it's click again it's closed


can it be or not ?
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiShare on FacebookShare on Stumble UponShare on Twitter
Reply With Quote
  #2 (permalink)  
Old 11-09-04, 04:26 AM
TwoD TwoD is offline
Community VIP
 
Join Date: Sep 2003
Location: 404
Posts: 1,813
Thanks: 0
Thanked 0 Times in 0 Posts
That's easy. Simply use an if-statement in the open function to check if the menu is open, and if it's not then close it.
You probably set the style.visibility property to 'visible' or something like that when the menu is opened, so it would be good to check that property to see if it's open or not.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiShare on FacebookShare on Stumble UponShare on Twitter
Reply With Quote
  #3 (permalink)  
Old 11-09-04, 07:50 AM
ramez ramez is offline
Newbie Coder
 
Join Date: Jul 2003
Posts: 42
Thanks: 0
Thanked 0 Times in 0 Posts
thanks


but how can i make it move down and all other menus move down
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiShare on FacebookShare on Stumble UponShare on Twitter
Reply With Quote
  #4 (permalink)  
Old 11-09-04, 01:21 PM
TwoD TwoD is offline
Community VIP
 
Join Date: Sep 2003
Location: 404
Posts: 1,813
Thanks: 0
Thanked 0 Times in 0 Posts
I'm not sure what you mean by move down...
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiShare on FacebookShare on Stumble UponShare on Twitter
Reply With Quote
  #5 (permalink)  
Old 12-16-04, 09:36 AM
ramez ramez is offline
Newbie Coder
 
Join Date: Jul 2003
Posts: 42
Thanks: 0
Thanked 0 Times in 0 Posts
how can i make the menu open or closed

like this


=================
||(O)|| Menu ||
=================

when theu user clike the O ... it's open like this

=================
||(X)|| Menu ||
=================
|| start ||
|| email ||
=================

and all the menus goes down
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiShare on FacebookShare on Stumble UponShare on Twitter
Reply With Quote
  #6 (permalink)  
Old 12-20-04, 07:35 PM
1jetsam 1jetsam is offline
Wannabe Coder
 
Join Date: Apr 2004
Posts: 128
Thanks: 0
Thanked 0 Times in 0 Posts
I made a menu with what little javascript skills I have. I want to create a program where users can make menus and set properties, so I'm not going to show the code.

Hint:
Code:
[...]layer.style.visibility = "hidden";[...]
This works in a lot more browsers and browser versions than other codes that get even more complex, but thats because its using more javascript, while this is actually using CSS (well and javascript).
__________________
Quate CMS 0.3.3 Released - A simple, fast Content Management System.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiShare on FacebookShare on Stumble UponShare on Twitter
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
Drop down menu trouble NCC1701 PHP 10 11-12-04 05:09 AM
Right Click Menu dwoody JavaScript 1 10-15-04 10:11 AM
Simple tree menu w/ html and js? zcorpan JavaScript 2 06-18-04 07:17 PM
edite right click menu leave >save as< masterblasters HTML/XHTML/XML 0 01-02-04 01:45 PM
putting content in a drop down menu tom PHP 7 07-04-03 03:25 PM


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