473,395 Members | 1,516 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,395 software developers and data experts.

Validations to the max!

havealot
Hey my friends , I have a task which is to validate a form for contact_us page , which consist of email,subject and the message.
my question is what validations do you think should I make ?

by now I've made email validation for the email format, and maximum and minimum chars limit for the subject with only letters available , and for the message only minimum number of char limit.

I hope you could help , thanks.
Jul 11 '15 #1

✓ answered by computerfox

Ideally, you'd want to validate the content if it's an actual query, especially if these will be posted on the website. Also, make sure you log some information such as IP address, it's really good for YOUR documentation and security. I do it on all of my websites. It's legal because you're not really grabbing anything from their machine, just their IP which every site does anyway and information about their browser through their header. Also, pages with underscores tend to have a negative affect for SEO and really doesn't look clean.

As for the email, you're only checking if it's "valid", but is it really valid? Is it a valid domain or a valid TLD? Does that email exist on that domain?

2 1322
computerfox
276 100+
Ideally, you'd want to validate the content if it's an actual query, especially if these will be posted on the website. Also, make sure you log some information such as IP address, it's really good for YOUR documentation and security. I do it on all of my websites. It's legal because you're not really grabbing anything from their machine, just their IP which every site does anyway and information about their browser through their header. Also, pages with underscores tend to have a negative affect for SEO and really doesn't look clean.

As for the email, you're only checking if it's "valid", but is it really valid? Is it a valid domain or a valid TLD? Does that email exist on that domain?
Jul 11 '15 #2
actually it's not what you think,
I'm not using any Databases for now, it's just a simple task to validate the inputs of the form using PHP.
Although I really want to know how to make this happen (getting IP address and Browser's Info).
about the email validation , what I meant is I validate the email format using PHP filter_var().

and finally I would like to thank you for these information :D
Jul 11 '15 #3

Sign in to post your reply or Sign up for a free account.

Similar topics

1
by: Naresh Agarwal | last post by:
Hi I'm using SAX Parser of Xerces Java v2.4.0 for XML Parsing. I want to perform schema validations on the xml. The problem is that root element of XML document does not have...
0
by: babash | last post by:
I designed a site with asp.net all pages are working properly on my local computer but when I upload the sit on the server on those pages that I have field validation, Buttons doesn’t work. When...
19
by: Gérard Talbot | last post by:
posted to: alt.html and comp.infosystems.www.authoring.html followup-to: comp.infosystems.www.authoring.html Hello all, I have 2 questions about validations. 1- What's basically the...
2
by: Jan | last post by:
Hi all, I have got the following problem: User fills in excel sheet, this is loaded in Acces. After this I run a validation tool to validate the field formats. One fields is allowed to be...
1
by: anil kumar via .NET 247 | last post by:
(Type your message here) hi, i am using save & cancel webform buttons in my webpage to withsome validations , when i am trying to save my content it issaved that time i need a popup msg like ur...
1
by: Anup | last post by:
In my form I and doing validations using 'Javascript' as I m using ASP1.1 and there is very less support for Validators there. //Code Behind private void Page_Load(object sender,...
2
by: prakashsurya | last post by:
Hello I am going through the validations in a form I would like to know the validations to be considered in writing javascript for email id so would u plz help me in writing the necessary...
2
by: swethak | last post by:
hi , i write the code in .htm file. It is in cgi-bin/searches/one.htm.In that i write a form submitting and validations.But validations are not worked in that .htm file. I used the same code in my...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
by: ryjfgjl | last post by:
In our work, we often receive Excel tables with data in the same format. If we want to analyze these data, it can be difficult to analyze them because the data is spread across multiple Excel files...
0
by: emmanuelkatto | last post by:
Hi All, I am Emmanuel katto from Uganda. I want to ask what challenges you've faced while migrating a website to cloud. Please let me know. Thanks! Emmanuel
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
marktang
by: marktang | last post by:
ONU (Optical Network Unit) is one of the key components for providing high-speed Internet services. Its primary function is to act as an endpoint device located at the user's premises. However,...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
by: Hystou | last post by:
Overview: Windows 11 and 10 have less user interface control over operating system update behaviour than previous versions of Windows. In Windows 11 and 10, there is no way to turn off the Windows...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.