hello friends.
WHY?
WHAT?
THE ISSUE?
THE EVIDENCE
<!--START: ShipQuote-->
<tr class="alternative">
<td class="item" width="150" align="right"><strong>[viewcart_shipping-header]</strong></td>
<td><input type="text" name="shipping_zip" size="14" value="[shipping_zip]" class="txtBoxStyle" id="Text3"></td>
<td width="15"><input type="button" value="Go!" class="btn" onClick="document.shipquote.shipping_zip.value=doc ument.recalculate.shipping_zip.value;document.ship quote.submit();" onMouseOver="this.className='btn_over'" onMouseOut="this.className='btn'" name="Button4"></td>
<td class="item">[viewcart_shipping-message]</td>
</tr>
<!--START: viewcart_ship-->
<tr class="alternative">
<td> </td>
<td class="item" colspan="4"> [shipping_city] [shipping_state] [shipping_zip]<br />
<select class="txtBoxStyle">
<!--START: Shippers-->
<option><b>[OPTION-SHIPPER]</b> <i>[OPTION-DESCRIPTION]</i> [OPTION-PRICE]</option>
<!--END: Shippers-->
</select>
<input type="button" class="btn" value="Clear" onClick="document.shipquote.action='shipquote.asp? action=clean';document.shipquote.submit();" onMouseOver="this.className='btn_over'" onMouseOut="this.className='btn'" id="Button5" name="Button5">
</td>
</tr>
<!--END: viewcart_ship-->
<!--END: ShipQuote-->
<!--START: ShipQuoteInternational-->
<tr class="alternative">
<td class="item" width="150" align="right"><strong>[viewcart_shipping-header]</strong></td>
<td class="item">
<script type="text/javascript" src="state_countryjs.asp"></script>
<script>
function get_Element(i)
{
return document.getElementById(i) || document.getElementsByName(i).item(0);
}
function getInternationalQuote()
{
var strAction = "shipquote.asp?shipping_country=" + get_Element("shipping_country").value;
strAction = strAction + "&shipping_state=" + get_Element("shipping_state").value;
document.shipquote.action = strAction;
document.shipquote.shipping_zip.value = document.recalculate.shipping_zip.value
document.shipquote.submit();
}
</script>
<select name="shipping_country" onChange="this.form.shipping_zip.value='';populate State('shipping_state','shipping_country');" class="txtBoxStyle" id="shipping_country"></select>
<span><select id="shipping_state" onChange="this.form.shipping_zip.value='';" name="shipping_state" class="txtBoxStyle"></select></span>
<input type="text" name="shipping_zip" size="14" value="[shipping_zip]" class="txtBoxStyle" id="shipping_zip">
</td>
<td width="15"><input type="button" value="Go!" class="btn" onClick="getInternationalQuote();" onMouseOver="this.className='btn_over'" onMouseOut="this.className='btn'" name="Button4" ID="Button1"></td>
<td class="item">[viewcart_shipping-message]</td>
</tr>
<!--START: viewcart_ship-->
<tr class="alternative">
<td> </td>
<td class="item" colspan="4"> [shipping_city] [shipping_state] [shipping_zip]<br />
<select class="txtBoxStyle" ID="Select1" NAME="Select1">
<!--START: Shippers-->
<option><b>[OPTION-SHIPPER]</b> <i>[OPTION-DESCRIPTION]</i> [OPTION-PRICE]</option>
<!--END: Shippers-->
</select>
<input type="button" class="btn" value="Clear" onClick="document.shipquote.action='shipquote.asp? action=clean';document.shipquote.submit();" onMouseOver="this.className='btn_over'" onMouseOut="this.className='btn'" id="Button2" name="Button5">
</td>
</tr>
<!--END: viewcart_ship-->
<!--END: ShipQuoteInternational-->
Thanks a bunch
ASIF
WHY?
- i need help with the shipping quote tool that is built into the shopping cart page.
- did nt get anywhere with the people on the helpdesks, so hopefully someone out in cyberspace can offer me assistance
- i do think this feature is already built-in, but is not functional, i dono why
WHAT?
- on the shopping cart page, there is a tool to estimate shipping
- however, it only works for US Zipcodes
- when you enter a zip, it looks up your shipping methods and spits out a shipping rate
- very handy for customers to get a quick idea of the "total cost" of their purchase
- the alternative is to "proceed to checkout" and enter your shipping information, to get the shipping rates
- but most potential customers don't do so, especially if they are not e-commerce savvy, they tend to avoid pressing the "proceed..." button
THE ISSUE?
- i was trying to figure out how to configure this tool to serve my canadian customers
- whereby, if they enter their state and country, they too can get a shipping rate estimate, right in the shopping cart
- does nt work, only works for US zipcodes
- but then, when i looked at the html code for the shopping cart page, view_cart.html, i was surprised to discover
- that there is a built-in international shipping calculator coded in!!!
- it just is not working, not sure why not????
THE EVIDENCE
- here is the html code, the first part is for the working US (zipcode input) quote, the second part is for the International (state, country input) quote.
- can someone help me get this working??
<!--START: ShipQuote-->
<tr class="alternative">
<td class="item" width="150" align="right"><strong>[viewcart_shipping-header]</strong></td>
<td><input type="text" name="shipping_zip" size="14" value="[shipping_zip]" class="txtBoxStyle" id="Text3"></td>
<td width="15"><input type="button" value="Go!" class="btn" onClick="document.shipquote.shipping_zip.value=doc ument.recalculate.shipping_zip.value;document.ship quote.submit();" onMouseOver="this.className='btn_over'" onMouseOut="this.className='btn'" name="Button4"></td>
<td class="item">[viewcart_shipping-message]</td>
</tr>
<!--START: viewcart_ship-->
<tr class="alternative">
<td> </td>
<td class="item" colspan="4"> [shipping_city] [shipping_state] [shipping_zip]<br />
<select class="txtBoxStyle">
<!--START: Shippers-->
<option><b>[OPTION-SHIPPER]</b> <i>[OPTION-DESCRIPTION]</i> [OPTION-PRICE]</option>
<!--END: Shippers-->
</select>
<input type="button" class="btn" value="Clear" onClick="document.shipquote.action='shipquote.asp? action=clean';document.shipquote.submit();" onMouseOver="this.className='btn_over'" onMouseOut="this.className='btn'" id="Button5" name="Button5">
</td>
</tr>
<!--END: viewcart_ship-->
<!--END: ShipQuote-->
<!--START: ShipQuoteInternational-->
<tr class="alternative">
<td class="item" width="150" align="right"><strong>[viewcart_shipping-header]</strong></td>
<td class="item">
<script type="text/javascript" src="state_countryjs.asp"></script>
<script>
function get_Element(i)
{
return document.getElementById(i) || document.getElementsByName(i).item(0);
}
function getInternationalQuote()
{
var strAction = "shipquote.asp?shipping_country=" + get_Element("shipping_country").value;
strAction = strAction + "&shipping_state=" + get_Element("shipping_state").value;
document.shipquote.action = strAction;
document.shipquote.shipping_zip.value = document.recalculate.shipping_zip.value
document.shipquote.submit();
}
</script>
<select name="shipping_country" onChange="this.form.shipping_zip.value='';populate State('shipping_state','shipping_country');" class="txtBoxStyle" id="shipping_country"></select>
<span><select id="shipping_state" onChange="this.form.shipping_zip.value='';" name="shipping_state" class="txtBoxStyle"></select></span>
<input type="text" name="shipping_zip" size="14" value="[shipping_zip]" class="txtBoxStyle" id="shipping_zip">
</td>
<td width="15"><input type="button" value="Go!" class="btn" onClick="getInternationalQuote();" onMouseOver="this.className='btn_over'" onMouseOut="this.className='btn'" name="Button4" ID="Button1"></td>
<td class="item">[viewcart_shipping-message]</td>
</tr>
<!--START: viewcart_ship-->
<tr class="alternative">
<td> </td>
<td class="item" colspan="4"> [shipping_city] [shipping_state] [shipping_zip]<br />
<select class="txtBoxStyle" ID="Select1" NAME="Select1">
<!--START: Shippers-->
<option><b>[OPTION-SHIPPER]</b> <i>[OPTION-DESCRIPTION]</i> [OPTION-PRICE]</option>
<!--END: Shippers-->
</select>
<input type="button" class="btn" value="Clear" onClick="document.shipquote.action='shipquote.asp? action=clean';document.shipquote.submit();" onMouseOver="this.className='btn_over'" onMouseOut="this.className='btn'" id="Button2" name="Button5">
</td>
</tr>
<!--END: viewcart_ship-->
<!--END: ShipQuoteInternational-->
Thanks a bunch
ASIF
Comment