%
if Len(Request.Form("validateInquiries")) > 0 then
Session("ValidationInquries") = "True"
Session("InquriesError") = ""
Dim email,full_name,contact_no,comments,company_name,city,country,project_brief
full_name = Request.Form("full_name")
contact_no = Request.Form("contact_no")
email = Request.Form("email")
project_brief = Request.Form("comments")
'city = Request.Form("City")
'country = Request.Form("country")
company_name = Request.Form("company_name")
'Response.Write(Request.ServerVariables("HTTP_REFERER"))
'REsponse.End()
If IsValidText(email) then
Session("ValidationInquries") = "False"
Session("InquriesError") = "*Invalid email! Please enter a valid email address.
"
End If
If IsValidText(full_name) then
Session("ValidationInquries") = "False"
Session("InquriesError") = Session("InquriesError") & "*Invalid name! Please enter a valid name.
"
End If
If IsValidText(city) then
Session("ValidationInquries") = "False"
Session("InquriesError") = Session("InquriesError") & "*Invalid City name! Please enter a valid City name.
"
End If
If IsValidText(country) then
Session("ValidationInquries") = "False"
Session("InquriesError") = Session("InquriesError") & "*Invalid Country name! Please enter a valid Country name.
"
End If
If IsValidText(contact_no) then
Session("ValidationInquries") = "False"
Session("InquriesError") = Session("InquriesError") & "*Invalid Phone no! Please enter a valid Phone no.
"
End If
If IsValidText(company_name) then
Session("ValidationInquries") = "False"
Session("InquriesError") = Session("InquriesError") & "*Invalid Company Name! Please enter a valid company name.
"
End If
If IsValidText(project_brief) then
Session("ValidationInquries") = "False"
Session("InquriesError") = Session("InquriesError") & "*Invalid Description! Please enter a valid description."
End If
If Session("ValidationInquries") = "True" and Session("InquriesError") = "" then
Response.Redirect("/contact_us_process.asp")
End If
Function IsValidText(TextField)
'Declare variables
Dim ValidText, TextParts, iLoopCounter, TextChar, unacceptableChars
ValidText = True 'set the default result to True
'acceptableChars are the characters that we will allow in our email
unacceptableChars = "<>/()"
'use the Split function to create an array with the @ as the separator
'so if your email was test@tester.com the email would be split into an array
'with the first array element holding "test" and the second "tester.com"
TextParts = Split(TextField, "<")
'Response.Write(emailParts)
'check to make sure that there is only 1 @ and that there are 2 parts
'remember arrays are zero based
'Using the UBound function will return the highest element in the array
'So if it's a valid email the UBound function will return 1, i.e. 0 start
'Response.End()
If UBound(TextParts) <> 1 Then
ValidText = false
End IF
For iLoopCounter = 1 to Len(TextField)
'Use Lcase & MID functions, MID function used to return each individual character
'in the email, and then Lcase converts it into lowercase
TextChar = Lcase(MID(TextField, iLoopCounter, 1))
'Check if the emailAddress characters are acceptable
If InStr(unacceptableChars, TextChar) <> 0 Then
ValidText = true
End if
Next
IsValidText = ValidText
End Function
End If
%>
 |
|
We are in this industry since 1997 and our valuable customers are top
fortune companies like LaSalle Bank, Walgreens, Synovate, Abott .etc. |
| Some of Our Clients We Served |
|
|
For more information /quotation / training details please dial 1-630-355-6292 (Monday - Friday: 8AM to 6PM), alternatively you can email us at info@royalcyber.com or Contact us and our team of consultants will assist you further. |
|
|
 |
|