<%@ LANGUAGE = VBScript %> <% 'Option Explicit %> <% Response.Expires = -1 %> <% Dim strUrl If strUseSecure = "Yes" Then strUrl = strSecureUrl Else strUrl = strCoUrl End If Dim strPage If (strGateway = "PayPal") Then strPage = "paypal_verify.asp" Else strPage = "cust_verify.asp" End If Dim strCity, strState, strZipCode, strCountryCode, strCartId, strResidential, strEmail, strPWD strCity = Request("City") strState = Request("State") strZipCode = Request("ZipCode") strCountryCode = Request("CountryCode") strCartId = Request("CartId") strResidential = Request("Residential") strEmail = Request("Email") strPWD = Request("PWD") Dim strShipCountryCode, strShipCountry Dim strShipAlternate strShipAlternate = Request.Form("ShipAlternate") Session("ShipAlternate") = strShipAlternate If Request.Form("B1") <> "" And Request.Form("ShipAlternate") = "No" Then Response.Redirect "error.asp?Error=You must choose Yes to alternate address if you use the Alternate Address Button." Response.End End If If strShipAlternate = "Yes" Then If Request.Form("ShipFName") = "" Then Response.Redirect "error.asp?Error=You must enter a First Name in the shipping area if you choose Yes to alternate address." Response.End ElseIf Request.Form("ShipLName") = "" Then Response.Redirect "error.asp?Error=You must enter a Last Name in the shipping area if you choose Yes to alternate address." Response.End ElseIf Request.Form("ShipAddress") = "" Then Response.Redirect "error.asp?Error=You must enter an Address in the shipping area if you choose Yes to alternate address." Response.End ElseIf Request.Form("ShipCity") = "" Then Response.Redirect "error.asp?Error=You must enter a City, Town or Province in the shipping area if you choose Yes to alternate address." Response.End ElseIf Request.Form("ShipState") = "Select State" Then Response.Redirect "error.asp?Error=You must enter a State in the shipping area if you choose Yes to alternate address." Response.End ElseIf Request.Form("ShipZipCode") = "" Then Response.Redirect "error.asp?Error=You must enter a Postal Code in the shipping area if you choose Yes to alternate address." Response.End End If ' Alt Shipping Info Dim strFirstLetter,strLetterCase Dim strShipFName strShipFName = trim(Request.Form("ShipFName")) strShipFName = Replace(strShipFName,Chr(039),"") strShipFName = Replace(strShipFName,Chr(034),"") strFirstLetter = Left(strShipFName,1) strLetterCase = Ucase (strFirstLetter) strShipFName = Replace(strShipFName,strFirstLetter,strLetterCase,1,1) Dim strShipLName strShipLName = trim(Request.Form("ShipLName")) strShipLName = Replace(strShipLName,Chr(039),"") strShipLName = Replace(strShipLName,Chr(034),"") strFirstLetter = Left(strShipLName,1) strLetterCase = Ucase (strFirstLetter) strShipLName = Replace(strShipLName,strFirstLetter,strLetterCase,1,1) Dim strShipCoName strShipCoName = trim(Request.Form("ShipCoName")) strShipCoName = Replace(strShipCoName,Chr(039),"") strShipCoName = Replace(strShipCoName,Chr(034),"") strFirstLetter = Left(strShipCoName,1) strLetterCase = Ucase (strFirstLetter) strShipCoName = Replace(strShipCoName,strFirstLetter,strLetterCase,1,1) Dim strShipAddress strShipAddress = trim(Request.Form("ShipAddress")) strShipAddress = Replace(strShipAddress,Chr(039),"") strShipAddress = Replace(strShipAddress,Chr(034),"") strFirstLetter = Left(strShipAddress,1) strLetterCase = Ucase (strFirstLetter) strShipAddress = Replace(strShipAddress,strFirstLetter,strLetterCase,1,1) Dim strShipAddress2 strShipAddress2 = trim(Request.Form("ShipAddress2")) strShipAddress2 = Replace(strShipAddress2,Chr(039),"") strShipAddress2 = Replace(strShipAddress2,Chr(034),"") strFirstLetter = Left(strShipAddress2,1) strLetterCase = Ucase (strFirstLetter) strShipAddress2 = Replace(strShipAddress2,strFirstLetter,strLetterCase,1,1) Dim strShipCity strShipCity = trim(Request.Form("ShipCity")) strShipCity = Replace(strShipCity,Chr(039),"") strShipCity = Replace(strShipCity,Chr(034),"") strFirstLetter = Left(strShipCity,1) strLetterCase = Ucase (strFirstLetter) strShipCity = Replace(strShipCity,strFirstLetter,strLetterCase,1,1) Dim strShipState strShipState = Request.Form("ShipState") Dim strShipZipCode strShipZipCode = trim(Request.Form("ShipZipCode")) Dim strArrayVal strArrayVal = split(Request.Form("ShipCountry"), ":", -1) strShipCountryCode = strArrayVal(0) strShipCountry = strArrayVal(1) If (strShipCountryCode <> "US" And Request("ShipState") <> "OutsideUSA") Then Response.Redirect "error.asp?Error=

You selected " & strShipCountry & " as your ship to Country." & _ "

Please choose Outside USA from the State drop down box." & _ "

Please use the back button to return." Response.End ElseIf (strShipCountryCode = "US" And Request("ShipState") = "OutsideUSA") Then Response.Redirect "error.asp?Error=

You selected " & strShipCountry & " as your ship to Country." & _ "

Please choose a State from the State drop down box." & _ "

Please use the back button to return." Response.End End If strCity = strShipCity strState = strShipState strZipCode = strShipZipCode strCountryCode = strShipCountryCode End If Session.Timeout = 60 If strState = "OutsideUSA" Then strState = "" End If Dim strSelect, xmlhttp, xmldoc, xml_Response, Response_Element, UPS_Rates, RatedShipment_Element, Total_Elements, Rates Dim UPS_ServiceCode, UPS_Amount, UPS_Descript, strError Function ups_shipping_rates() DIM mySQL3, objRS3, strWeight Set objRS3 = Server.CreateObject("ADODB.Recordset") mySQL3 = "SELECT SUM(TotalWeight) AS Weight FROM Cart Where CartId = '"& strCartId &"'" objRS3.Open mySQL3, objConn strWeight = objRS3("Weight") If strWeight < 1 Then strWeight = 1 End If 'Response.Write strWeight 'Response.End Dim strXML strXML="" & strXMLLicense & "" strXML=strXML & "" & strUserId & "" & strPassword & " " strXML=strXML & "" strXML=strXML & "Rating and Service1.0001" strXML=strXML & "Rate" strXML=strXML & "Shop" strXML=strXML & "" & strPickupTypeCode & "" strXML=strXML & "" & strCustomerClassCode & "" strXML=strXML & "" If strShipperNumber <> "" Then strXML=strXML & "" & strShipperNumber & "" End If strXML=strXML & "
" strXML=strXML & "" & strCoCity & "" strXML=strXML & "" & strCoState & "" strXML=strXML & "" & strCoZip & "" strXML=strXML & "" & strCoCountryCode & "" strXML=strXML & "
" strXML=strXML & "
" strXML=strXML & "
" strXML=strXML & "" & strCity & "" strXML=strXML & "" & strState & "" strXML=strXML & "" & strZipCode & "" strXML=strXML & "" & strCountryCode & "" If strResidential = "Yes" Then strXML=strXML & "" End If strXML=strXML & "
" strXML=strXML & "" & "11" & "" strXML=strXML & "" & strPackageTypeCode & "" strXML=strXML & "Package" strXML=strXML & "Rate Shopping" strXML=strXML & "" & strWeight & "" strXML=strXML & "" & "" & "
" strSelect = "" Response.Write strSelect End Function %> UPS Shipping Rates text="#<%= strText %>" link="#<%= strLink %>" vlink="#<%= strVLink %>" alink="#<%= strALink %>">

Shipping Rates provided by UPS®



Please choose a shipping option.

<% Call ups_shipping_rates() %>

UPS®, UPS & Shield Design® and UNITED PARCEL SERVICE® are registered trademarks of United Parcel Service of America, Inc.