Forum Moderators: travelin cat

Message Too Old, No Replies

iMac and Javascript dropdown incompatible?

User cannot access via my dropdown

         

DebW

10:40 pm on Jun 7, 2006 (gmt 0)

10+ Year Member



I am new at scripting -- and everything else, too. When our nonprofit can afford a webmaster, I will be so happy! Anyway, I was thrilled to get a dropdown menu to work on my site, even though I had to resort to using several because I couldn't get my head around the cascading variety. Then, one of my directors tells me he cannot access the pages, since I moved from the pages long lists (in HTML) to the JS dropdowns!
I cannot duplicate the problem on either my desktop PC, or my wireless PC, and he's in Montana. He can view the pages if I send him the urls, but he cannot by selecting from any of the dropdowns.

My code looks like this:
<select name="jumpit4" onchange="document.location.href=this.value">
<option selected value="">Montana</option>
<option value="http://x.org\Folder\x.html">Alberton</option>
</select>

(I removed the actual option values in deference to the posting guidelines, but I know they are not the problem. Like I said, it works for me!)

He's using iMac OS 10.4.6, and has tried it with both: Netscape 7.2 and IE 5.2.3. Any suggestions?

whoisgregg

1:36 pm on Jun 8, 2006 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Do you actually use back slashes "\" in your code? All slashes in URLs should be forward slashes "/"

I tested your code and found it to be working in these browsers:
Safari (current)

It did not work in the following browsers until I fixed the back slashes into forward slashes, then it worked:
Mac IE 5.2.3
Firefox (current)
Mozilla 1.7 (same as Netscape 7.2)

He's using iMac OS 10.4.6, and has tried it with both: Netscape 7.2 and IE 5.2.3. Any suggestions?

Tell him to delete IE 5.2.3. Seriously, it's both discontinued and a horrible product for user and developer.

Oh, and Welcome to WebmasterWorld [webmasterworld.com], DebW!

timster

4:49 pm on Jun 8, 2006 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Have you downloaded the FireFox browser? If you're going to be testing webpages, it's a must these days.

DebW

11:17 pm on Jun 8, 2006 (gmt 0)

10+ Year Member



Thanks, guys, you rock! I did a mass change on all the wrong slashes (sounds like a country song) and sent my user your recommend. So far, so good. My next step is to download the foxfire.

I hope all my life's goofs are so easy to fix, and there's always someone around like you to get me back on track!

8)

Lorel

2:58 pm on Jun 21, 2006 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member Top Contributors Of The Month



Hi Deb W

If you want the keywords in the link text to be read by search engines you might be better served by finding a drop down code that utilizes HTML with JavaScript and also CSS as Search Engines cannot read JS. The MyGoSuMenu does so.

StupidScript

7:07 pm on Jun 26, 2006 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



Have you tried:

<select name="jumpit4" onchange="document.location.href=[b]this.options.selectedIndex.value[/b]">

for backwards compatibility ...?

StupidScript

8:04 pm on Jun 26, 2006 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



this.options.selectedIndex.value

should be:

this.options[this.selectedIndex].value

Sorry 'bout that! Been too wrapped up in other languages for awhile ... :)