My NOP product code looks like this:
<!--Shopping Cart Product Begin-->
<P><FORM NAME=order ACTION="managecart.html" onSubmit="AddToCart(this)">
Quantity: <input type=text size=2 maxlength=3 name=QUANTITY onChange='this.value=CKquantity(this.value)' value="1">
<input type=hidden name="PRICE" value="39">
<input type=hidden name="NAME" value="UK Black Kirk">
<input type=hidden name="ID_NUM" value="001">
<select name="SHIPPING">
<option value="0">Select shipping</option>
<option value="0">UK Second Class Recorded Free</option>
<option value="1.05">UK First Class Recorded £1.05</option>
<option value="7.85">Europe Recorded Airmail £7.85</option>
<option value="10.45">Worldwide Recorded Airmail £10.45</option>
</select>
<input type="image" src="UKpay.gif" border=0 value="Add to Cart" align=top>
</FORM>
<!--Shopping Cart Product End -->
This works excellently, but I used to have a bit of code above my items which made sure that customers choose a shipping option, stopping the <option value="0">Select shipping</option> from being selected.
The code above the items was
<script type="text/javascript">
<!-- Hide JS from HTL validators
function SetShip (obj1) { // record selected shipping option
var obj,pos;
obj = obj1.SHIPPING; // refer to shipping select
pos = obj.selectedIndex; // get selection
if (pos == 0) { // force a selection
alert ("Make a shipping selection!");
return false;
}
</script>
And then the form statement looked like this:
<form target="paypal" action="https://www.paypal.com/cgi-bin/webscr" method="post" onsubmit="iced.target='paypal';
return SetShip (iced);">
How do I incorporate the "return SetShip" statement into the new NOP form statement?
Thanks guys!
