Generating a contact form for a website can be a rather tedious job. To make things easier there are a number of WordPress plugins available, one in particular which is rather good is Contact Form 7. This allows you to create a form and generate a number of tags for display on that form, e.g. email address, name, comments…

contactform71

You can then include this on your WordPress site via a new post or page using the following syntax:

 PHP |  copy |? 
[contact-form 1 "ContactForm"]

It supports CAPTCHA, simple quizzes, various different components for generating surveys, contact forms etc… It also supports localization of messages so that you can customize the error messages and text displayed.

One issue I did find with it however was that I wanted to embed the contact form in a template. At first this doesn’t seem to be possible unless you use another plugin. I used Improved include page which allows you to include a wordpress page in a template. By creating a new page with a contact form embedded it’s very easy to include this page in your template:

And you have a contact form which can be embedded in the footer of your page or wherever you choose to put it.