Home Articles FAQs XREF Games Software Instant Books BBS About FOLDOC RFCs Feedback Sitemap
irt.Org
#

Q1452 Using a drop down menu, how can I get to another page by just clicking on the page title within the menu, rather than use the 'Go' button?

You are here: irt.org | FAQ | JavaScript | Form | Q1452 [ previous next ]

Try:

<form>
<select onChange="if (this.options[this.selectedIndex].value != "") location.href=this.options[this.selectedIndex].value">
<option>--Select a Link--
<option value="http://www.irt.org">irt.org
</select>
</form>

However the button will be needed in 16 bits browsers since they do need to be clicked somewhere else for the onChange to register.

©2018 Martin Webb