Click to See Complete Forum and Search --> : Compatibility problem with window.frame.location


msmith29063
06-06-2003, 10:53 PM
I'm using the following code for a pull down menu in a header frame for a site. It works on Netscape and Safari (Mac), but doesn't work for IE (PC). It worked until I added "main". Keep in mind that this is the target frame. Any help would be greatly appreciated. Thank you.

<form>
<select name="url" onchange="window.main.location=url.value;">
<option>Choose...</option>
<option value="giftshop/index.asp">Gift Shop</option>
<option value="sitemap/index.asp">Site Map</option>
<option value="tour/index.asp">Hospital Tour</option>
<option value="weather/index.asp">Health and Weather</option>
<option value="micromedix/index.asp">Micromedix</option>
<option value="micromedix/index.asp">- Drug Directory</option>
</select>
</form>

pyro
06-06-2003, 10:59 PM
Try this:

onchange="top.main.href=this.options[this.selectedIndex].value;"

msmith29063
06-06-2003, 11:11 PM
I can't test on my PC at this time, but now it doesn't work on any of my Mac browsers. Any ideas? Thank you so much for your help.

Mr J
06-07-2003, 08:42 AM
Can you post the code?

pyro
06-07-2003, 09:34 AM
Try this instead...

onchange="top.main.location.href=this.options[this.selectedIndex].value;"

msmith29063
06-07-2003, 10:28 AM
It works on Mac browsers now. I'll run it through the "grinder" on my PC. Thank you so much for your help. I learned a lot!