Forum     

Go Back   Digit Technology Discussion Forum > Portables, Peripherals and Electronics > QnA (read only)
Register FAQ Calendar Mark Forums Read

QnA (read only) Mods please help transfer the contents of this forum to proper sections. :)


 
 
LinkBack Thread Tools Search this Thread Display Modes
Old 10-12-2004, 01:46 PM   #1 (permalink)
Right Off the Assembly Line
 
Join Date: Jul 2004
Posts: 34
Default drop down menus


Recently I created a website for myself, I used the "select" HTML control and designed it, it's code is given below. Thee problem is that I can open up a page only when i change from one option to another but not when in the same option. Like in the "--header--" option in the menu is default selected, so if I press again header, it wont work since there is no change in the selection. Could anyone plz help me.
Also if u could tell me how to show the menu when we hover the mouse, I would be grateful to u.
-----------------------------------------------------------------------
<STYLE type=text/css>.networkbarselect {
FONT-SIZE: 11px; COLOR: #333333; FONT-FAMILY: Arial, Helvetica,sans-serif;BACKGROUND-COLOR: #f2f2f2
}</STYLE>

<SCRIPT language=JavaScript type=text/JavaScript>
function MM_jumpMenu(targ,selObj,restore){
var i;
i=selObj.selectedIndex;
selObj.selectedIndex=0;
eval(targ+".location='"+selObj.options[i.value+"'");
}</SCRIPT>

<select class=networkbarselect onchange="MM_jumpMenu('window.document',this,1)">
<option value=javascript:// selected>--header--</option>
<option value=http://www.yahoo.com>yahoo</option>
<option value=http://www.rediff.com>rediff</option>
</select>
----------------------------------------------------
sridhar8310 is offline  
Advertisements. Register and be a member of the community to get rid of them.
Advertisement

Old 10-12-2004, 03:49 PM   #2 (permalink)
Wise Old Owl
 
Join Date: Jul 2004
Location: Bangalore
Posts: 1,208
Default

The select control behaves in the way which you have mentioned. Everytime you select an option in the control certain events get triggered and hence it implements whatever is there in the code of the event called. In your case since the --header-- is already selected even if you select it again nothing will happen as no even gets triggered.

As for your second option use DHTML menus. They give you lot more flexibility and look very pretty too! Loads of tools are available to build them. Just google it!
__________________
AMD 64 3500+ Venice
DFI Lan Party Ultra-D
2* 512 MB PdP Memory with 2-2-5L timings
XFX 7900GT 256 MB Card
icecoolz is offline  
Old 10-12-2004, 05:11 PM   #3 (permalink)
Version 2.0
 
Deep's Avatar
 
Join Date: Jan 2004
Location: Mumbai
Posts: 977
Default

http://www.dynamicdrive.com/dynamici...pmenuindex.htm


or

http://www.opencube.com/nav_online.html (pretty good)

i hope this solves your problem
Deep
__________________
- Deep Ganatra -
www.whoisdeep.com
www.twitter.com/DeepXP/
Deep is offline  
 

Bookmarks

Thread Tools Search this Thread
Search this Thread:

Advanced Search
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 On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


 
Latest Threads
- by abhidev
- by Sarath
- by clmlbx
- by ico
- by clinton

Advertisement




All times are GMT +5.5. The time now is 02:07 AM.


Powered by vBulletin® Version 3.8.7
Copyright ©2000 - 2012, vBulletin Solutions, Inc.

Search Engine Optimization by vBSEO 3.3.2