Stand Alone PHP Contact Form

I wanted to build code for a contact form that could be added to any page with a simple line of code such as this:

This version of the form verifies that all fields are filled out. As well as the name field only accepts alpha(a-z) characters, dashes, apostrophes, periods, and spaces. The email field verifies that it follows this standard email format. The phone number field only accepts numbers, spaces, dashes, periods, plus symbols, and parenthesis. The comment field only checks to make sure you put something in it.

The functionality to send the information filled out on the form has been disabled for this demo.

Leave a Reply