<%@ Application Language="VB" %> <% ' uncomment thing section to turn the quoting system off 'if Session.Contents("admin") = "true" then ' this session variable will only be true if the admin is logged in ' offline = false 'else ' offline = true 'end if indir = trim(Request.form("dir")) FName = trim(request.form("FName")) LName = trim(request.form("LName")) Address1 = trim(request.form("Address1")) Address2 = trim(request.form("Address2")) city = trim(request.form("city")) state = trim(request.form("state")) zipCode = trim(request.form("zipCode")) phone = trim(request.form("phone")) email = trim(request.form("email")) pType = trim(request.form("Type")) Pzipcode = trim(request.form("Pzipcode")) Pcity = trim(request.form("Pcity")) Pstate = trim(request.form("Pstate")) Dzipcode = trim(request.form("Dzipcode")) Dcity = trim(request.form("Dcity")) Dstate = trim(request.form("Dstate")) %> Shipping Done Right


Menu:

<% if not offline then %>
Address Information
Customer Information
First Name:
*
Last Name:
Address:
Address 2:
City:
State:
Zip:
*
Phone:
Email:
*
<%if pType = "" then pType = "Pack and Ship"%> Estimate Type: /> Pack and Ship /> Pack Only /> Ship Only
Pickup Information <% if Request.form("SDD") = "" then %> <% else Response.write Request.form("SDD") end if %>
Pickup Zip Code:
OR Pickup City:

Pickup State:

Delivery Information <% if request.form("DDD") = "" then %> <% else Response.Write Request.form("DDD") end if %>
Delivery Zip Code:
OR Delivery City:

Delivery State:
<% for each x in request.form td = UCase(x) if td = "FNAME" or td = "LNAME" or td = "ADDRESS1" or td = "ADDRESS2" or td = "CITY" or td = "STATE" or td = "ZIPCODE" _ or td = "PHONE" or td = "EMAIL" or td = "TYPE" or td = "PZIPCODE" or td = "PCITY" or td = "PSTATE" or td = "DZIPCODE" _ or td = "DCITY" or td = "DSTATE" or td = "DDD" or td = "SDD" then else %> <% end if next %>
Without a valid pickup, delivery and email address we will not be able to correctly process your quote.
<% else sitedown end if %>
<% sub sitedown Response.Write "The quoting system is offline, please come back at a later time." DBPath = "..\database\sdr.mdb" Set MyCon = Server.CreateObject("ADODB.Connection") Set MyRS = Server.CreateObject("ADODB.RecordSet") MyCon.Open "Provider=Microsoft.Jet.OLEDB.4.0;Data Source="+Server.MapPath(DBPath)+";" MySQL = "select * from Admin where [desc] = 'email'" MyRs.Open MySql, MyCon, 1, 3 if not myrs.eof then myrs.movefirst if not myrs.eof then ToEmail = MyRs.Fields(1) myrs.close if toemail <> "" then Dim objEmail Set objEmail = CreateObject("CDO.Message") With objEmail.Configuration.Fields .Item("http://schemas.microsoft.com/cdo/configuration/sendusing") = 2 .Item("http://schemas.microsoft.com/cdo/configuration/smtpserver") = "smtpout.secureserver.net" .Item("http://schemas.microsoft.com/cdo/configuration/sendusername") = "sales@shippingdoneright.com" .Item("http://schemas.microsoft.com/cdo/configuration/sendpassword") = "sales" .Item("http://schemas.microsoft.com/cdo/configuration/smtpauthenticate") = 1 .Item("http://schemas.microsoft.com/cdo/configuration/smtpserverport") = 80 .Update End With strBody = "" & vbCrLf _ & "" & vbCrLf _ & "" & vbCrLf _ & " Quote System usage request" & vbCrLf _ & " " & vbCrLf _ & "" & vbCrLf _ & ""& vbCrLf _ & "Someone tried to use the quoting system.
Time: " & now & vbcrlf _ & "" & vbcrLf %> " & vbCrLf <% objEmail.From = "sales@shippingdoneright.com" objEmail.To = toEmail objEmail.Subject = "Quote System" objEmail.HtmlBody = strBody objEmail.Send Set objEmail = Nothing end if end sub %>