In one of my scripts, a user fills in their email address and a message. When they submit the form, the info is stored in my database and a copy of the message is sent to me. I am able to validate the email address, but what kind of validating do I have to do on the users message to make sure that no errors are caused when sending the email or adding it to the database? (like stripping the html tags, quotes, etc).
Also, I want to keep spaces. For example, without doing anything, if the user fills in this:
test
test
I will get an email that looks like this:
test
test
How do I keep the spacing?
Thanks in advance,
Joe