Author roger on 04-10-2002 at 09:01 (EST)
|hi edmund thanks alot previously on the INPUT EXAMPLE 4 option |
i was able to add additional input options. kinda understand it now
but i have one other request
INPUT EXAMPLE 4 APPLET
see the drop down list of shirt sizes
i want to put in modifiyer.. where
it adds price to cost
S + $2.00
M + $4.00
L + $6.00
XL + $8.00
I want to add the extra cost to the alrady given price
how do i go about that?
|Table Of Contents|
| RE: ushop Bill Weiner, 2002-04-11 05:41:19 (1)|
|Messages In This Discussion|
| 1. RE: ushop|
Author Bill Weiner on 04-11-2002 at 05:41 (EST)
// Define a new variable for the price.
var price = 24.95;
// Define a new variable for the size.
var size = document.P00004.size.options[document.P00004.size.selectedIndex].value;
// Add to the price based on the size.
if (size == "S")
price = price + 2.0;
else if (size == "M")
price = price + 4.0;
else if (size == "L")
price = price + 6.0;
price = price + 8.0;
And then just substitue the "price" and the "size" variable in the document.uShopJSI.addProduct() call.