#121: A Template for Generic Pages

(Updated on )

We look at the contact page and decide that it’s the kind of page on CSS-Tricks that is very generic and doesn’t need any particular special styling at all. Really the only difference between a generic page and a blog post is that there are no comments and no date (both rather irrelevant for this type of content).

When you publish a page in WordPress and leave it as the default template (don’t choose anything from the dropdown, and remember dropdown is only there if you actually have multiple template), it uses the page.php file in your theme.

We whip this page.php template into shape in this video. We use the grid structure we have set up. We make the content of the page a generic div (rather than an article, since articles are for individually syndicatable bits of content, which we can’t be sure any page is). Our contact page is just an embedded Wufoo form.

We end up looking at a few other pages that will very likely use this same generic template.