Create a Contact Form

It’s always a great idea to make it as easy as possible for your subscribers and for your blog visitors to contact you directly. Now, instead of just displaying your email address, which may be picked up by spam bots, and as a result you may end up in a lot of spam, you can also just install a simple contact form to your WordPress blog.

[evp width=”640″ height=”480″]tutorials/wpvideos/contact-form.swf[/evp]

In your WordPress dashboard, you can just search for the search term Contact Form, and you will find a lot of suitable WordPress plugins that you can use and install. Now, the first plugin that you see here, WP Contact Form by Ryan Duff, used to be one of the more popular plugins; however, this plugin seems to be rather inactive lately, so another good alternative is Contact Form 7. Now, the names here may all seem very much alike to the new user, so I want you to look for the name of the creator of this plugin, which is Takayuki Miyoshi, alright? So, what you can do is install this Contact Form 7 to your WordPress blog either automatically or manually.

Once you have uploaded the plugin you can just activate it, and you will see on your left-hand column a new section here for the contact form. So I’m just gonna click on Edit.

And there’s some basic setup that is required for your contact form. The first, of course, you need to put in your actual email address where you want to receive inquiries and where you want people to send their inquiries to, and then the rest of the fields, basically, you can just leave it as it is if you just want to create a very simple contact form, alright? And once you’ve updated the contact form settings, you can just copy this code and then go to a page or a, or also on a blog post, and right in the content area here, I’m just going to paste that code that we got earlier, ‘cause I’m going to save this page… and let’s take a look at that page to see how a contact form looks like.

Okay, so this is the basic default contact form that comes with the plugin, and you don’t have to configure it at all. Your subscribers would just put your name, email address, subject, type in their message here and send. So once they click Send, then you’d be able to receive the inquiries in your Gmail or whatever it is, whatever email system that you are using.

Now, let’s take a look at the contact form settings page again, and see how you can add additional fields or functions to your contact form. The first thing you’d want to do is click on Generate Tag and then just choose the field that you want to put in. So for example, if I want my subscribers to be able to upload any attachment to their email, I can just choose File Upload. And then I can either make this a required field or not. I can leave it as optional. I can also put in a file size limit here and also acceptable file types.

For example, if I only want to accept PDF, then I’ll only type in ‘.pdf’, and so on. Okay? So, this is the code that you need to copy and paste into your contact form in this area here to add in the field. Now, if you understand basic HTML, this can be very, very easy for you to do, but if you don’t, I’m going to show you a rather easier way.

First thing you need to do is just copy this entire thing, paste it here, and then just start editing the field information from there, onwards.
Okay, so you can see, I’ve added a new heading for the attachments, and then I’m just gonna copy over this code here, and paste it into this section here.

Okay, so once that’s done, I’m just gonna click on Save, and now let’s take a look at the changes that I’ve just made in my contact form. As you can see, this is the default contact form that comes with the plugin itself, and I’m gonna refresh this page…yup. So now, you can see that there’s a new attachments field that comes right here, and the users can just attach any file that they want to.

So let’s take a look at a few more tricks that you can use to design your contact form. By default, the Submit button just says Send. But if you want to change the text, then just change the text within the brackets here.

Okay, it’s just a minor customization but it really helps to make your contact form look friendly. You can save that. And we’re gonna see how the changes look like. So this is the default Send button. I’m gonna refresh this page. And you can see now the Send button has changed to Send Me Your Thoughts.

Another thing that most people like to do is that instead of leaving the subject field as an open-ended entry, they would like to create some categories, so it’ll be easier for them to sort through the emails, et cetera. So to do that, just click on Generate Tag and click on Drop-down menu, alright? So I’m gonna enter some choices here, some categories that my subscribers would see in the contact form itself.

So you can see, I’ve added a few choices. Now I want to make this a required field, alright, and if I want to allow multiple selections, I can do that as well, but in most cases I just want to allow them to just choose one category so it’ll be easier for me to sort through my emails. And then probably I want to insert a blank item as the first option to force people to actually choose the correct option here, so I’m going to select this code – copy, and in the subject field, instead of using the default codes here, I’m just going to paste…okay. So now I’m going to hit on Save, and let’s take a look at our contact form earlier.

This is how the subject field is to look like, a very open-ended subject field. I’m going to refresh. Alright, and now you can see a blank subject has been entered by default, and the user can now select which category, for example, if they want to inquire about your products, then they can just click on Product Inquiries and type in their message here.

And finally, let’s take a look at some of the custom messages that you can put into the contact form. If you look at the plugin page, under Messages, click on Show, and here you’ll see the complete list of messages, some of which is seen by the user and others that are seen only by you. So, for example, if once – once a user clicks Submit on the contact form then what does he see after that? So this is the default message, which is ‘Your message was sent successfully. Thanks’. So let’s say I want to change this, I’m gonna change this to a more meaningful auto-respond message.

Okay, so I’ve changed that to ‘Thanks for contacting me, I will reply in 48 hours.’ And then you can just go on to customize this as much as you want, and click on Save.

Using the contact form plugin for WordPress, you can have not just one form but in fact, you can create as many forms as you want. So as you create more forms, you may want to rename the forms accordingly, and the easiest way to do this is to click on the form name, and then just change this name to whatever you want.

And then click on Save. So you can see here that the name has been changed to Default Contact Form. So that’s how easy it is to start putting up contact forms on your WordPress blogs, and getting inquiries and just regular emails from your subscribers.