Debt Consolidation - Military Loans - Credit Cards - Debt Consolidation - Bollywood India forum movie reviews

PDA

View Full Version : small problem greenz for answer


klown
Nov 22nd 2006, 6:47 pm
I have a small problem with a form, it works in FF but not in IE.

I have a select menu


<select name="system" id="system">
<option value="/resources/bmicalculator.php" <?php if ($system=="us") {} else {echo "selected";}?> onClick="jump('/resources/bmicalculator.php');">Metric System</option>
<option value="/resources/bmicalculator.php?system=us" <?php if ($system=="us") {echo "selected";}?> onClick="jump('/resources/bmicalculator.php?system=us');">US System</option> </select>

when somebody clicks on one of the selections it jumps them to a different page with the following js


function jump(address)
{
document.location.href=address;
}


any idea whats wrong?

nico_swd
Nov 23rd 2006, 12:25 am
Do


<select name="system" id="system" onchange="jump(this.value);">


EDIT:

And it should be window.location

ajsa52
Nov 23rd 2006, 3:03 pm
I use the following:

<select name="system" id="system" onchange="jump(this.value);" onFocus="jump(this.value);">