NYFashionToGo
Technical User
Please bare with me I am brand new to Javascript, I have done some other coding with VBA.
I am trying to build a shipping calculator to post on a Website. I am little confused on how to do something, Or how to make it happen. I am short on some of the terms.
I eliminated alot of the code Below due to redundancy of it and changed some of the numbers..
First Column to the Left. This is the first 3 digits of a USA zip code. Instead of being a drop down (that would be insane hard for buyer to get) I would Like a text box where they simply type in the 5 digit zip.. I match the first three digits and pull the data accordingly.
The Other columns I do not want to have a drop down Menu at all. Just the result displayed based on the zip code typed..
Im trying to learn this stuff. Please bare with me.
I realize that if I loose the drop down for the zip. I loose everything. Part of my problem.. I not certain how to set it up so it does that.
Any insight whould be helpful and appreciated.
Thank You
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=windows-1252">
<title>New Page 1</title>
</head>
<body>
<table id=AutoNumber1 style="BORDER-COLLAPSE: collapse" bordercolor="#111111" cellspacing="0" cellpadding="0" width="72%" border="1">
<tr>
<td align="center"><font color="#404040" size="2">U.S. Zip Code</font></td>
<td align="center"><font size="2" color="#404040">1 Pound Package</font></td>
<td align="center"><font size="2" color="#404040">2 Pound Package</font></td>
<td align="center"><font size="2" color="#404040">3 pound Package</font></td>
<td align="center"><font size="2" color="#404040">4 Lb Package</font></td>
</tr>
<tr>
<form name="sizing">
<td align="center"><font color="#404040" size="2">
<select name="USA" size="1" onChange="javascript:
for (var i = 0; i<document.sizing.elements.length; i++) {
if ((document.sizing.elements.type == 'select-one')) {
document.sizing.elements.selectedIndex = this.selectedIndex;
}
}">
<option>988</option>
<option>989</option>
<option>990</option>
<option>991</option>
<option>992</option>
<option>993</option>
<option>994</option>
<option>995</option>
<option>996</option>
<option>997</option>
<option>998</option>
<option>999</option>
</select>
</font></td>
<td align="center"><font color="#404040" size="2">
<select name="USA_Named" size="1" onChange="javascript:
for (var i = 0; i<document.sizing.elements.length; i++) {
if ((document.sizing.elements.type == 'select-one')) {
document.sizing.elements.selectedIndex = this.selectedIndex;
}
}">
<option>4.60</option>
<option>4.60</option>
<option>4.60</option>
<option>4.60</option>
<option>4.60</option>
<option>4.60</option>
<option>4.60</option>
<option>4.60</option>
<option>4.60</option>
<option>4.60</option>
<option>4.60</option>
<option>4.60</option>
</select>
</font></td>
<td align="center"><font color="#404040" size="2">
<select name="UK" size="1" onChange="javascript:
for (var i = 0; i<document.sizing.elements.length; i++) {
if ((document.sizing.elements.type == 'select-one')) {
document.sizing.elements.selectedIndex = this.selectedIndex;
}
}">
<option>7.50</option>
<option>8.50</option>
<option>9.50</option>
<option>9.75</option>
<option>10.50</option>
<option>11.50</option>
<option>12.00</option>
<option>13.00</option>
<option>14.00</option>
<option>14.50</option>
<option>15.00</option>
<option>16.00</option>
</select>
</font></td>
<td align="center"><font color="#404040" size="2">
<select name="Australia" size="1" onChange="javascript:
for (var i = 0; i<document.sizing.elements.length; i++) {
if ((document.sizing.elements.type == 'select-one')) {
document.sizing.elements.selectedIndex = this.selectedIndex;
}
}">
<option>12.00</option>
<option>13.00</option>
<option>14.00</option>
<option>15.00</option>
<option>16.00</option>
<option>17.00</option>
<option>18.00</option>
<option>19.00</option>
<option>20.00</option>
<option>21.00</option>
<option>22.00</option>
<option>23.00</option>
</select>
</font></td>
<td align="center"><font color="#404040" size="2">
<select name="Germany" size="1" onChange="javascript:
for (var i = 0; i<document.sizing.elements.length; i++) {
if ((document.sizing.elements.type == 'select-one')) {
document.sizing.elements.selectedIndex = this.selectedIndex;
}
}">
<option>15.00</option>
<option>16.00</option>
<option>17.00</option>
<option>18.00</option>
<option>19.00</option>
<option>20.00</option>
<option>21.00</option>
<option>22.00</option>
<option>23.00</option>
<option>24.00</option>
<option>25.00</option>
<option>26.00</option>
</select>
</font></td>
</form>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
<tr>
<td>
<br />
<!
</body>
</html>
I am trying to build a shipping calculator to post on a Website. I am little confused on how to do something, Or how to make it happen. I am short on some of the terms.
I eliminated alot of the code Below due to redundancy of it and changed some of the numbers..
First Column to the Left. This is the first 3 digits of a USA zip code. Instead of being a drop down (that would be insane hard for buyer to get) I would Like a text box where they simply type in the 5 digit zip.. I match the first three digits and pull the data accordingly.
The Other columns I do not want to have a drop down Menu at all. Just the result displayed based on the zip code typed..
Im trying to learn this stuff. Please bare with me.
I realize that if I loose the drop down for the zip. I loose everything. Part of my problem.. I not certain how to set it up so it does that.
Any insight whould be helpful and appreciated.
Thank You
<html>
<head>
<meta http-equiv="Content-Type" content="text/html; charset=windows-1252">
<title>New Page 1</title>
</head>
<body>
<table id=AutoNumber1 style="BORDER-COLLAPSE: collapse" bordercolor="#111111" cellspacing="0" cellpadding="0" width="72%" border="1">
<tr>
<td align="center"><font color="#404040" size="2">U.S. Zip Code</font></td>
<td align="center"><font size="2" color="#404040">1 Pound Package</font></td>
<td align="center"><font size="2" color="#404040">2 Pound Package</font></td>
<td align="center"><font size="2" color="#404040">3 pound Package</font></td>
<td align="center"><font size="2" color="#404040">4 Lb Package</font></td>
</tr>
<tr>
<form name="sizing">
<td align="center"><font color="#404040" size="2">
<select name="USA" size="1" onChange="javascript:
for (var i = 0; i<document.sizing.elements.length; i++) {
if ((document.sizing.elements.type == 'select-one')) {
document.sizing.elements.selectedIndex = this.selectedIndex;
}
}">
<option>988</option>
<option>989</option>
<option>990</option>
<option>991</option>
<option>992</option>
<option>993</option>
<option>994</option>
<option>995</option>
<option>996</option>
<option>997</option>
<option>998</option>
<option>999</option>
</select>
</font></td>
<td align="center"><font color="#404040" size="2">
<select name="USA_Named" size="1" onChange="javascript:
for (var i = 0; i<document.sizing.elements.length; i++) {
if ((document.sizing.elements.type == 'select-one')) {
document.sizing.elements.selectedIndex = this.selectedIndex;
}
}">
<option>4.60</option>
<option>4.60</option>
<option>4.60</option>
<option>4.60</option>
<option>4.60</option>
<option>4.60</option>
<option>4.60</option>
<option>4.60</option>
<option>4.60</option>
<option>4.60</option>
<option>4.60</option>
<option>4.60</option>
</select>
</font></td>
<td align="center"><font color="#404040" size="2">
<select name="UK" size="1" onChange="javascript:
for (var i = 0; i<document.sizing.elements.length; i++) {
if ((document.sizing.elements.type == 'select-one')) {
document.sizing.elements.selectedIndex = this.selectedIndex;
}
}">
<option>7.50</option>
<option>8.50</option>
<option>9.50</option>
<option>9.75</option>
<option>10.50</option>
<option>11.50</option>
<option>12.00</option>
<option>13.00</option>
<option>14.00</option>
<option>14.50</option>
<option>15.00</option>
<option>16.00</option>
</select>
</font></td>
<td align="center"><font color="#404040" size="2">
<select name="Australia" size="1" onChange="javascript:
for (var i = 0; i<document.sizing.elements.length; i++) {
if ((document.sizing.elements.type == 'select-one')) {
document.sizing.elements.selectedIndex = this.selectedIndex;
}
}">
<option>12.00</option>
<option>13.00</option>
<option>14.00</option>
<option>15.00</option>
<option>16.00</option>
<option>17.00</option>
<option>18.00</option>
<option>19.00</option>
<option>20.00</option>
<option>21.00</option>
<option>22.00</option>
<option>23.00</option>
</select>
</font></td>
<td align="center"><font color="#404040" size="2">
<select name="Germany" size="1" onChange="javascript:
for (var i = 0; i<document.sizing.elements.length; i++) {
if ((document.sizing.elements.type == 'select-one')) {
document.sizing.elements.selectedIndex = this.selectedIndex;
}
}">
<option>15.00</option>
<option>16.00</option>
<option>17.00</option>
<option>18.00</option>
<option>19.00</option>
<option>20.00</option>
<option>21.00</option>
<option>22.00</option>
<option>23.00</option>
<option>24.00</option>
<option>25.00</option>
<option>26.00</option>
</select>
</font></td>
</form>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
</table>
</td>
</tr>
<tr>
<td>
<br />
<!
</body>
</html>