Forums

This topic is locked

Hi. I'm new here but got a question

Posted 07 Jul 2005 18:12:14
1
has voted
07 Jul 2005 18:12:14 lol Swordtip posted:
Hello. I was wondering if you guys would give me a helping hand. The thing is I'm making a web "page" that calculates shipping charge in $. I want the user to input pounds and then to select a state. When they select a certain number of pounds(ie; 12) and they select a state(New York) they get the shipping fee($22.95). I also want to be able to do so with international countries. I have the shipping charts so if you ready to help me I can email you them. My current code is:

<pre id=code><font face=courier size=2 id=code>&lt;?xml version="1.0" encoding="UTF-8"?&gt;
&lt;!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.1//EN" "www.w3.org/TR/xhtml11/DTD/xhtml11.dtd"&gt;
&lt;html xmlns="www.w3.org/1999/xhtml" xml:lang="en"&gt;
&lt;head&gt;
&lt;script type="text/javascript"&gt;
&lt;/script&gt;
&lt;script type="text/javascript"&gt;
function getFee() {
alert('Shipping fee is '+document.zipform.us_states.value*document.zipfor m.weight.value);
}
&lt;/script&gt;

&lt;form action="google.ca" name="zipform" target="_blank"&gt;
&lt;input type="hidden" name="OZ" value="l3j8s1"&gt;

&lt;b&gt; &lt;BR&gt;Shipping Calculator&lt;/b&gt;&lt;P&gt;&lt;P&gt;&lt;P&gt;&lt;/h1&gt;&lt;b&gt;Weight in POUNDS:&lt;/b&gt; &lt;input type="text" name="weight" tabindex="2" size="6" maxlength="6"&gt;
&lt;br
&lt;input type="hidden" name="LP" value="package"&gt;&lt;input type="hidden" name="Char" value="4"&gt;&lt;input type="hidden" name="OV" value="off"&gt;&lt;input type="hidden" name="BL" value="off"&gt;&lt;input type="hidden" name="Dir" value="forward"&gt;&lt;input type="hidden" name="retspec" value="no"&gt;
&lt;br&gt;&lt;b&gt;Buyers State if in US: &lt;/b&gt;
&lt;select name="us_states" size="1"&gt;
&lt;option value="" selected="selected"&gt;None&lt;/option&gt;
&lt;option value="$26.25"&gt;AL Alabama&lt;/option&gt;
&lt;option value="Unkown"&gt;AK Alaska&lt;/option&gt;
&lt;option value="$29.25"&gt;AZ Arizona&lt;/option&gt;
&lt;option value="$26.25"&gt;AR Arkansas&lt;/option&gt;
&lt;option value="$28.95"&gt;CA California&lt;/option&gt;
&lt;option value="$28.95"&gt;CO Colorado&lt;/option&gt;
&lt;option value="$24.00"&gt;CT Connecticut&lt;/option&gt;
&lt;option value="$24.00"&gt;DE Delaware&lt;/option&gt;
&lt;option value="$23.90"&gt;DC District of Columbia&lt;/option&gt;
&lt;option value="$26.25"&gt;FL Florida&lt;/option&gt;
&lt;option value="$26.25"&gt;GA Georgia&lt;/option&gt;
&lt;option value="Unknown"&gt;HI Hawaii&lt;/option&gt;
&lt;option value="$28.95"&gt;ID Idaho&lt;/option&gt;
&lt;option value="$23.90"&gt;IL Illinois&lt;/option&gt;
&lt;option value="$28.95"&gt;IN Indiana&lt;/option&gt;
&lt;option value="$24.30"&gt;IA Iowa&lt;/option&gt;
&lt;option value="$26.25"&gt;KS Kansas&lt;/option&gt;
&lt;option value="$24.30"&gt;KY Kentucky&lt;/option&gt;
&lt;option value="$26.25"&gt;LA Louisiana&lt;/option&gt;
&lt;option value="$24.30"&gt;ME Maine&lt;/option&gt;
&lt;option value="$24.00"&gt;MD Maryland&lt;/option&gt;
&lt;option value="$24.00"&gt;MA Massachusetts&lt;/option&gt;
&lt;option value="$23.90"&gt;MI Michigan&lt;/option&gt;
&lt;option value="Unkown"&gt;MN Minnesota&lt;/option&gt;
&lt;option value="$26.25"&gt;MS Mississippi&lt;/option&gt;
&lt;option value="$26.25"&gt;MO Missouri&lt;/option&gt;
&lt;option value="$28.95"&gt;MT Montana&lt;/option&gt;
&lt;option value="$26.25"&gt;NE Nebraska&lt;/option&gt;
&lt;option value="$29.25"&gt;NV Nevada&lt;/option&gt;
&lt;option value="$24.00"&gt;NH New Hampshire&lt;/option&gt;
&lt;option value="$24.00"&gt;NJ New Jersey&lt;/option&gt;
&lt;option value="$28.95"&gt;NM New Mexico&lt;/option&gt;
&lt;option value="$22.95"&gt;NY New York&lt;/option&gt;
&lt;option value="$24.30"&gt;NC North Carolina&lt;/option&gt;
&lt;option value="$26.25"&gt;ND North Dakota&lt;/option&gt;
&lt;option value="$23.90"&gt;OH Ohio&lt;/option&gt;
&lt;option value="$26.25"&gt;OK Oklahoma&lt;/option&gt;
&lt;option value="$26.25"&gt;OR Oregon&lt;/option&gt;
&lt;option value="$24.00"&gt;PA Pennsylvania&lt;/option&gt;
&lt;option value="$24.00"&gt;RI Rhode Island&lt;/option&gt;
&lt;option value="$24.30"&gt;SC South Carolina&lt;/option&gt;
&lt;option value="$26.25"&gt;SD South Dakota&lt;/option&gt;
&lt;option value="$24.30"&gt;TN Tennessee&lt;/option&gt;
&lt;option value="$26.25"&gt;TX Texas&lt;/option&gt;
&lt;option value="$28.95"&gt;UT Utah&lt;/option&gt;
&lt;option value="$24.00"&gt;VT Vermont&lt;/option&gt;
&lt;option value="$24.00"&gt;VA Virginia&lt;/option&gt;
&lt;option value="$28.95"&gt;WA Washington&lt;/option&gt;
&lt;option value="$24.00"&gt;WV West Virginia&lt;/option&gt;
&lt;option value="$24.30"&gt;WI Wisconsin&lt;/option&gt;
&lt;option value="$28.95"&gt;WY Wyoming&lt;/option&gt;
&lt;/select&gt;

&lt;BR&gt;&lt;input type=submit value="submit" name=zipok accesskey='c' onclick="getFee();"&gt;&lt;/form&gt;&lt;P&gt;&lt;P&gt;
&lt;br&gt;
&lt;br&gt;
&lt;br&gt;
&lt;/head&gt;
&lt;body&gt;
&lt;/body&gt;
&lt;/html&gt; </font id=code></pre id=code>

Thanks.

Reply to this topic