View Full Version : Evil Drop Down Box!!!!!


slink11
05-10-2003, 10:14 PM
the drop down box isn't working !!! Here's the code i put in but i wanted to have 10 options but it only give me the first 5 i put up well i clicked one of the options then i clicked go well it wouldn't open the page it said page not found but i need HELP !!! ITS AGORVATING ME !!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!!

quiksilver_dude
05-10-2003, 10:20 PM
could you like post the code?

slink11
05-10-2003, 10:25 PM
bbbbb name="gotolocation2" method="POST">
<select name="lissamenu4" size=1
style="font-family: comic sans ms"
style="color: "FFFFFF"
style="border: outset"
style="font-size: 12"
style="background: #00FFFF">
<option value="http://horseland.com/bbbbbts/PCKHORSES.asp?" style=background-color:<BFFCCFF;color:000000>Horses</option>
<option value="http://horseland.com/bbbbbts/PCKOWNERS.asp?" style=background-color:ccccff;color:000000>Players</option>
<option value="http://horseland.com/bbbbbts/PCKSHOWS.asp?" style=background-color:ff99ff;color:000000>Shows</option>
<option value="http://horseland.com/bbbbbts/STORE.asp?" style=background-color:9999ff;color:000000>Store</option>
<option value="http://horseland.com/bbbbbts/NEWS.asp?" style=background-color:ff66ff;color:000000>News</option>
<option value="http://horseland.com/talk/newstop.html
"style=background-color:<BFFCCFF;color:000000>Chat</option>
</select>
<input type="button" style="font-family: comic sans ms"
style="color: #000000"
style="font-size: 9"
style="background: CC99FF" onClick="location =
document.gotolocation2.lissamenu4.options
[document.gotolocation2.lissamenu4.selectedIndex].value;"
value="BYE">
</form>

quiksilver_dude
05-10-2003, 10:26 PM
You didn't start it with <form> I don't see anything else wrong though anyways you only posted 5 options not ten!

slink11
05-10-2003, 10:30 PM
still not working when i would select something then click go it would say the object is null (it's being ran on scripts)

i put ten but i had to take them off because of space and they wouldn't show up anyways when i press the drop button

slink11
05-10-2003, 10:37 PM
this is exactly what i was given:
<form name="gotolocation1" method="POST">
<select name="lissamenu1" size=1
style="font-family: comic sans ms"
style="color: #FFFF00"
style="border: outset"
style="font-size: 12"
style="background: #CC99FF">
<option value="http://www.lissaexplains.com">Lissa Explains it All</option>
<option value="http://www.lissaexplains.com/cursor.shtml">Lissa's Cursors</option>
<option value="http://www.lissaexplains.com/home">Lissa's Page</option>
</select>
<input type="button" style="font-family: comic sans ms"
style="color: #FF0000"
style="font-size: 12"
style="background: #CC99FF" onClick="location =
document.gotolocation1.lissamenu1.options
[document.gotolocation1.lissamenu1.selectedIndex].value;"
value="Go">
</form>

after changes it looked like that up there

amicus
05-11-2003, 01:20 AM
i'm not sure what the problem is 'cos the code is working. i cleaned it out a little so hopefully it'll be a little easier to understand :).

<html>
<head>
<style type="text/css">
select {
background: #CC99FF;
font-family: "comic sans ms";
color: #FFFF00;
font-size: 12;
border: outset;
}

input {
background: #CC99FF;
font-family: "comic sans ms";
color: #FF0000;
font-size: 12;
}
</style>

<script language="javascript">
/**
* Goto url being passed in
*/
function gotoLocation( url ) {
location = url;

return true;
}
</script>
</head>

<body>
<select name="lissamenu1" size=1>
<option value="http://www.lissaexplains.com">Lissa Explains it All</option>
<option value="http://www.lissaexplains.com/cursor.shtml">Lissa's Cursors</option>
<option value="http://www.lissaexplains.com/home">Lissa's Page</option>
</select>

<input type="button" value="Go" onClick="javascript:gotoLocation(lissamenu1.value)">
</body>
</html>

'javascript' is one word, for some reason it gets broken up.

slink11
05-11-2003, 02:11 AM
thanx like alots but i wanted to fit 10 options on there when i put the sites and names down it looked liked that when i pressed save (when i looked at the html part.)

it looked like this: bbbbb>
<select name="lissamenu1" size=1
style="font-family: comic sans ms"
style="color: #FFFF00"
style="border: outset"
style="font-size: 12"
style="background: #CC99FF">
<optionvalue="http://horseland.com/PCKHORSES.asp?">Horses</option>
<optionvalue="http://horseland.com/PCKOWNERS.asp?">Players</option>
<optionvalue="http://horseland.com/PCKSHOWS.asp?">Shows</option>
</select>
<input type="button" style="font-family: comic sans ms"
style="color: #FF0000"
style="font-size: 12"
style="background: #CC99FF" onClick="location =
document.gotolocation1.lissamenu1.options
[document.gotolocation1.lissamenu1.selectedIndex].value;"
value="Bye">
</form>

after i pressed save

please do not double post, use the edit button. --Moderator

amicus
05-11-2003, 02:34 AM
what do you mean 10 options? you can have as many options as you want. do you mean you want 10 options displaying at a time?

slink11
05-11-2003, 02:38 AM
it worked great thanx alot i still can't figure it out but my friend is helping me but if she don't know i have u on buddy so i'lll send u a pm in case

slink11
05-11-2003, 02:47 AM
you know how when you press the down button it'll say those 3 options well i want it to say 10 put i need to know what i'll have to type everytime i want it repeated if u want to show me an example just use url horseland.com (words: Horseland Home)

amicus
05-11-2003, 02:31 PM
i think this is what you want :). remember 'javascript' is one word and the 'input' tag goes on one line. for some reason that's getting broken up too.

also if you're linking to your own website you don't need the 'http://www.horseland.com/' part. just use relative paths.

<html>
<head>
<style type="text/css">
select {
background: #CC99FF;
font-family: "comic sans ms";
color: #FFFF00;
font-size: 12;
border: outset;
}

input {
background: #CC99FF;
font-family: "comic sans ms";
color: #FF0000;
font-size: 12;
}
</style>

<script language="javascript">
/**
* Goto url being passed in
*/
function gotoLocation( url ) {
location = url;

return true;
}
</script>
</head>

<body>
<select name="lissamenu1" size="1">
<option value="http://www.lissaexplains.com/">Lissa Explains it All</option>
<option value="http://www.lissaexplains.com/cursor.shtml">Lissa's Cursors</option>
<option value="http://www.lissaexplains.com/home">Lissa's Page</option>
<option value="http://www.horseland.com/">Horse Land</option>
<option value="http://www.horseland.com/">Horse Land 2</option>
<option value="http://www.horseland.com/">Horse Land 3</option>
<option value="http://www.horseland.com/">Horse Land 4</option>
<option value="http://www.horseland.com/">Horse Land 5</option>
<option value="http://www.horseland.com/">Horse Land 6</option>
<option value="http://www.horseland.com/">Horse Land 7</option>
<option value="http://www.horseland.com/">Horse Land 8</option>
<option value="http://www.horseland.com/">Horse Land 9</option>
<option value="http://www.horseland.com/">Horse Land 10</option>
</select>

<input type="button" value="Go" onClick="javascript:gotoLocation(lissamenu1.value)">
</body>
</html>