Is There any way i can link a drop down menu?

This is a discussion on "Is There any way i can link a drop down menu?" within the Web Page Design section. This forum, and the thread "Is There any way i can link a drop down menu? are both part of the Design Your Website category.



 Subscribe in a reader

Go Back   Webforumz.com > Main Forums > Design Your Website > Web Page Design

Notices


Reply
 
LinkBack Thread Tools
  #1  
Old Apr 30th, 2006, 10:50
Highly Reputable Member
Join Date: Jul 2005
Location: Northampton, England
Age: 19
Posts: 506
Thanks: 0
Thanked 0 Times in 0 Posts
Cool Is There any way i can link a drop down menu?

is there any way that i can get this menu to link to a page ?

Code: Select all
<SELECT NAME="Favorite_Color" SIZE="1">
<OPTION SELECTED>Blue
<OPTION>Red
<OPTION>Yellow
<OPTION>Green
<OPTION>Black
<OPTION>Orange
<OPTION>Purple
</SELECT></B> 
-Thanks Bruno
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote

  #2  
Old Apr 30th, 2006, 11:48
Rob's Avatar
Rob Rob is online now
Webforumz Founder
Join Date: Jul 2003
Location: Southern UK
Age: 34
Posts: 3,157
Blog Entries: 7
Thanks: 26
Thanked 19 Times in 16 Posts
Re: Is There any way i can link a drop down menu?

I think you are looking for this:
HTML: Select all
<script type="text/javascript">
<!--
// original code by Bill Trefzger 12/12/96
function go1(){
if (document.selecter1.select1.options[document.selecter1.select1.selectedIndex].value != "none") {
location = document.selecter1.select1.options[document.selecter1.select1.selectedIndex].value
        }
    }
//-->
</script>
<script type="text/javascript">
<!--
document.write('<form name="selecter1"><select name="select1" size=1>');
document.write('<option value="none">Select your destination</option>');
document.write('<option value="none">--------------------</option>');
document.write('<option value="page1.html">Page 1</option>');
document.write('<option value="page2.html">Page 2</option>');
document.write('<option value="page 3.html">Page 3</option>');
document.write('</select>');
document.write('  <input type="button" value="Go" onclick="go1()">');
document.write('</form>');
// end hiding contents -->
</script>
You can make the select box work as soon as you make a selection (without having to click go) by changing the select tag to:-
<select name="select1" size="1" onclick="go1()">
__________________
Click the 'Thanks!' button if this post has helped you

Rob - Webforumz Founder

Last edited by Rob; May 1st, 2006 at 09:46.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
  #3  
Old May 1st, 2006, 04:02
herkalees's Avatar
Highly Reputable Member
Join Date: Jul 2005
Location: Massachusetts, USA
Age: 87
Posts: 576
Thanks: 0
Thanked 0 Times in 0 Posts
Re: Is There any way i can link a drop down menu?

Drop the case of all your element and attribute names, and close those option elements.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
  #4  
Old May 1st, 2006, 09:45
Rob's Avatar
Rob Rob is online now
Webforumz Founder
Join Date: Jul 2003
Location: Southern UK
Age: 34
Posts: 3,157
Blog Entries: 7
Thanks: 26
Thanked 19 Times in 16 Posts
Re: Is There any way i can link a drop down menu?

Hey Herk...

Dont shoot the copy / paste boy. (I updated the nicked code above)

lol.
__________________
Click the 'Thanks!' button if this post has helped you

Rob - Webforumz Founder
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
  #5  
Old May 1st, 2006, 12:28
herkalees's Avatar
Highly Reputable Member
Join Date: Jul 2005
Location: Massachusetts, USA
Age: 87
Posts: 576
Thanks: 0
Thanked 0 Times in 0 Posts
Re: Is There any way i can link a drop down menu?

Quote:
Originally Posted by Rob
Hey Herk...

Dont shoot the copy / paste boy. (I updated the nicked code above)

lol.
No worries, I was actually referring to our friend up there.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
  #6  
Old May 1st, 2006, 14:17
Most Reputable Member
Join Date: Apr 2006
Location: Cornwall, UK
Posts: 1,310
Thanks: 0
Thanked 0 Times in 0 Posts
Re: Is There any way i can link a drop down menu?

Quote:
Originally Posted by bruno89
is there any way that i can get this menu to link to a page ?
Although the capability to do so exists as has been shown. Why would you want to?

It's not very user intuitive as a navigational form and has accessibility ramifications. On that latter matter, it has been argued that you should not invoke an action just on the change of selection as some potential users won;t follow what has happened.
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
  #7  
Old May 9th, 2006, 17:47
Highly Reputable Member
Join Date: Jul 2005
Location: Northampton, England
Age: 19
Posts: 506
Thanks: 0
Thanked 0 Times in 0 Posts
Re: Is There any way i can link a drop down menu?

well i don't actualy want it a friend of mine asked me *haha*
Digg this Post!Add Post to del.icio.usBookmark Post in TechnoratiFurl this Post!Spurl this Post!Reddit! Wong this Post!
Reply With Quote
Reply

Tags
link, drop, down, menu

Thread Tools

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

Similar Threads
Thread Thread Starter Forum Replies Last Post
Drop Down Menu alexgeek JavaScript Forum 8 Oct 22nd, 2007 12:52
Drop-down Menu kaz JavaScript Forum 1 May 24th, 2007 10:32
Drop-down Menu kaz JavaScript Forum 7 May 23rd, 2007 10:05
I have a normal css menu, but want ot add drop down menu to it multichild Web Page Design 7 Jan 9th, 2007 16:07
Drop Menu Help xKillswitchx Web Page Design 1 Jul 13th, 2005 17:56


All times are GMT. The time now is 17:02.


Powered by vBulletin®
Copyright ©2000 - 2008, Jelsoft Enterprises Ltd.
Search Engine Optimization by vBSEO 3.2.0 RC8
© 2003-2008 Webforumz.com : All Rights Reserved

1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42