A contact form is pretty much a necessity for any website these days, creating one is fairly simple. Making them look good is where the real skill lies. By using some simple Css rules your forms can really rock!

This is what we are aiming to end up with;
Preview

Live Preview

form full
The Mark-up

There are many elements that make up a form, some of which are neglected or seen as not necessary. But its important to include these for Accessibility reasons, lets take a look at a simple contact form.

Contact Form

Please fill in your details


This will give us a basic form structure, I am not going to explain what each tag does, as this tutorial aim is how to style them.

However if you wish to find out a little more, there is a great explanation on Forms over at W3schools.com
Adding extra markup

As there are many tags within the form there will be many styles that need to be created.

However as many of the tags will be styled the same, it would be easier to group them. That way we can drastically cut down the number of rules within our Css.

How are we going to do this? Simple, we can use our trusty unordered list

    and list tags
  • .

    First we need to decide what elements we wish to group. The logical answer would be our
    and our form , Lets do that.

    You may have notice that I have used 2 unordered lists, this is so we can style the