<%@ Language=VBScript %><% const ForAppending = 8 const TristateFalse = 0 function LogRequest(strReq) dim fs, folder, item, strNewPath, strFileName LogRequest = false strNewPath = Server.MapPath("/reqlogs") strFileName = strNewPath & "\" & "Requests_" & Year(Now()) & Month(Now()) & Day(Now()) & ".log" set fs = CreateObject("Scripting.FileSystemObject") Set logFile = fs.OpenTextFile(strFileName, ForAppending, True, TristateFalse) logFile.WriteBlankLines 1 logFile.WriteLine "-------------------------------------------" & Now() logFile.WriteLine strReq logFile.WriteLine "-------------------------------------------" logFile.Close end function dim strRedirect 'Response.Write Request.Form & "
" if Request.Form.Count <> 0 then strRedirect = Trim(Request.Form("redirect") & " ") firstname = Trim(Request.Form("firstname") & " ") lastname = Trim(Request.Form("lastname") & " ") company = Trim(Request.Form("company") & " ") address = Trim(Request.Form("address") & " ") city = Trim(Request.Form("city") & " ") state = Trim(Request.Form("state") & " ") country = Trim(Request.Form("country") & " ") zip = Trim(Request.Form("zip") & " ") phone = Trim(Request.Form("phone") & " ") fax = Trim(Request.Form("fax") & " ") email = Trim(Request.Form("textfield") & " ") autodealership = Trim(Request.Form("autodealership") & " ") church = Trim(Request.Form("church") & " ") countryclub = Trim(Request.Form("countryclub") & " ") financial = Trim(Request.Form("financial") & " ") manufactureing = Trim(Request.Form("manufactureing") & " ") medical = Trim(Request.Form("medical") & " ") profoff = Trim(Request.Form("profoff") & " ") restaurant = Trim(Request.Form("restaurant") & " ") retail = Trim(Request.Form("retail") & " ") salon = Trim(Request.Form("salon") & " ") other = Trim(Request.Form("other") & " ") dealer = Trim(Request.Form("dealer") & " ") comments = Trim(Request.Form("comments") & " ") hear = Trim(Request.Form("howhear") & " ") if email = "" then email = "sales@lrspagers.co.uk" end if strBody = "First name: " & firstname & vbCrLf _ & "Last name: " & lastname & vbCrLf _ & "Company: " & company & vbCrLf _ & "Address: " & address & vbCrLf _ & "City: " & city & vbCrLf _ & "State: " & state & vbCrLf _ & "Country: " & country & vbCrLf _ & "Zip Code: " & zip & vbCrLf _ & "Phone: " & phone & vbCrLf _ & "Fax: " & fax & vbCrLf _ & "Email: " & email & vbCrLf _ & "Comments: " & comments & vbCrLf _ & "How did you hear about us: " & hear & vbCrLf if autodealership = "checkbox" then strBody = strBody & "Auto Dealership: YES" & vbCrLf else strBody = strBody & "Auto Dealership: NO" & vbCrLf end if if church = "checkbox" then strBody = strBody & "Church: YES" & vbCrLf else strBody = strBody & "Church: NO" & vbCrLf end if if countryclub = "checkbox" then strBody = strBody & "Country Club: YES" & vbCrLf else strBody = strBody & "Country Club: NO" & vbCrLf end if if financial = "checkbox" then strBody = strBody & "Financial Institution: YES" & vbCrLf else strBody = strBody & "Financial Institution: NO" & vbCrLf end if if manufactureing = "checkbox" then strBody = strBody & "Manufacturing Facility: YES" & vbCrLf else strBody = strBody & "Manufacturing Facility: NO" & vbCrLf end if if medical = "checkbox" then strBody = strBody & "Medical/Healthcare: YES" & vbCrLf else strBody = strBody & "Medical/Healthcare: NO" & vbCrLf end if if profoff = "checkbox" then strBody = strBody & "Professional Offices: YES" & vbCrLf else strBody = strBody & "Professional Offices: NO" & vbCrLf end if if restaurant = "checkbox" then strBody = strBody & "Restaurant: YES" & vbCrLf else strBody = strBody & "Restaurant: NO" & vbCrLf end if if retail = "checkbox" then strBody = strBody & "Retail: YES" & vbCrLf else strBody = strBody & "Retail: NO" & vbCrLf end if if salon = "checkbox" then strBody = strBody & "Salons/Health Spas: YES" & vbCrLf else strBody = strBody & "Salons/Health Spas: NO" & vbCrLf end if if other = "checkbox" then strBody = strBody & "Other: YES" & vbCrLf else strBody = strBody & "Other: NO" & vbCrLf end if if dealer = "checkbox" then strBody = strBody & "Dealer: YES" & vbCrLf else strBody = strBody & "Dealer: NO" & vbCrLf end if 'Response.Write strBody & "
" dim oMailer 'The ASPMail object 'On Error Resume Next Set oMailer = Server.CreateObject("SMTPsvg.Mailer") oMailer.RemoteHost = "mail.lrspagers.co.uk" oMailer.FromName = firstname & " " & lastname oMailer.FromAddress = email oMailer.AddRecipient "LRS Sales", "sales@lrspagers.co.uk" oMailer.AddRecipient "LRS Sales", "sales@lrspagers.co.uk" oMailer.Subject = "REQUEST INFO FORM" oMailer.BodyText = strBody dim blnResult blnResult = true blnResult = oMailer.SendMail Set oMailer = Nothing bln = LogRequest(strBody) 'Response.Write "blnResult="&blnResult&"
" if blnResult then if strRedirect = "" then Response.Redirect "http://www.lrspagers.co.uk/response.htm" else Response.Redirect strRedirect end if else Session("message") = "An error has occurred sending the request." end if end if %> Request Info

Complete this form to receive information and pricing.
* Required Fields

*First Name
*Last Name
Organization
*Phone No:  
County
*E-mail
Comments
* How did you hear about us?  

Your Industry (Please check all that apply)

Auto Dealership Church Country Club
Financial Institution Manufacturing Facility Medical/Healthcare
Professional Offices Restaurant Retail Store
Salons/Health Spas
Other
Dealer


 

statistics