"
errorCount = errorCount + 1
end if
whichReferer = Request.ServerVariables("HTTP_REFERER")
whichReferer = replace(whichReferer,"www.","")
whichReferer = replace(whichReferer,".co.uk","")
whichReferer = replace(whichReferer,".co.uk","")
whichReferer = replace(whichReferer,"http://","")
whichReferer = left(whichReferer,11)
if whichReferer <> "axistelecom" then
validReferer = "
HTTP referer is not correct
"
errorCount = errorCount + 1
end if
if Request.ServerVariables("REQUEST_METHOD") <> "POST" then
validPost = "
Form was not posted
"
errorCount = errorCount + 1
end if
badStrings = array("Content-Type%3A","MIME-Version%3A","Content-Transfer-Encodin%3A","bcc%3A","cc%3A")
checkFormString = Request.Form.Item
For Each badWord in badStrings
if InStr(1,checkFormString, badWord,1) <> 0 then
response.write(badWord)
validString = "
Bad string found
"
errorCount = errorCount + 1
end if
next
if company_name = "" then
validCompanyName = ("
Please enter your Company Name
")
errorCount = errorCount + 1
end if
if contact_name = "" then
validContactName = ("
Please enter your Contact Name
")
errorCount = errorCount + 1
end if
if address1 = "" then
validaddress1 = ("
Please enter your address
")
errorCount = errorCount + 1
end if
'check the email is equal to something and contains a fullstop and @ sign
if email = "" or inStr(email,"@") = 0 or inStr(email,".") = 0 then
validEmail = ("
Please enter a valid email
")
errorCount = errorCount + 1
end if
if post_town = "" then
validpost_town = ("
Please enter your post town
")
errorCount = errorCount + 1
end if
if telephone = "" then
validtelephone = ("
Please enter your telephone number including STD code
")
errorCount = errorCount + 1
end if
if post_code = "" then
validpost_code = ("
Please enter your post code
")
errorCount = errorCount + 1
end if
if errorCount <> 0 then
errMsg = "
If you would like to request further information on our Axis Telecom products
either call our customer service team on 0844 875 1942 or complete the form below:
<%=errMsg%>
<% else
response.write(contactEmailSent)
end if %>