Hey all, I’m a bit new to JavaScript so bear with me!
My main Website uses the Paypal buy it now buttons which i have found i can manipulate by using drop down menus.
What i Want to do now is capture 2 values from each option (one to alter the despcription one to alter the price) but i’m failing to succeed.
This is what I have (edited out the non relevant bits)
[I]the code bit
[code]
function hondachainselect()
{
document.hondachain.item_name.value = document.hondachain.hondachainproduct.value + document.hondachain.hondachain_bike.value
}
[I]the html form bit[/I]
<form target=”paypal” action=”https://www.paypal.com/cgi-bin/webscr” method=”post” name=”hondachain”>
<b> Please Choose your colour:<br></b>
<select name=”hondachain_bike” onChange=”hondachainselect()”>
<option value=” 0 “>Choose Bike</option>
<option value=”CRF50 04-06″ >CRF50 04-06 £19.99</option>
<option value=”CRF70 04-06″ >CRF70 04-06 £19.99</option>
<option value=”CRF100 04-06″ >CRF100 04-06 £29.99</option>
</select>
<br><font size=”4″><b>from £19.99</b><br></font>
<input type=”hidden” name=”hondachainproduct” value=”Chain & Sprocket Kit – “>
<input type=”image” src=”https://www.paypal.com/en_GB/i/btn/x-click-but22.gif” border=”0″ name=”submit” alt=”Make payments with PayPal – it’s fast, free and secure!”>
<input type=”hidden” name=”item_name”>
<input type=”hidden” name=”amount”>
</form>
with that the “item_name” comes out correctly but I’ve given up how to get a 2nd value from the options to assign to “amount”
Many thanks in advance for your help!!