drop down java script in frontpage

  • Thread starter Louis & Nanci Mart
  • Start date
L

Louis & Nanci Mart

I have a drop down menu script that creates a clickable drop down list. What
I would like to do is not have it open a new page. Have it open in the same
page. Can anyone tell me what to change in the script below?

Also if I wanted to use it in a frames site how would I change the script?

Thanks,
Louis

<script> function goToPage(url) { if (url != "") {
..open(url); } }</script><form> <label><u>S</u>earch Engines</label> <select
accesskey="S" onchange="goToPage(this.options(this.selectedIndex).value)">
<option selected>Please select one</option> <option
value="http://search.msn.com/">MSN Search</option> <option
value="http://www.google.com/">Google</option> <option
value="http://www.search.com/">Search.com</option> <option
value="http://www.dogpile.com/">Dogpile</option> </select>form>
 
J

Jon Spivey

Hi,
Change
if (url != "") { .open(url); }
to
if (url != "") {location.href=url; }
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Similar Threads


Top