Vary WordPress templates for different pages

Project Overview

It never hurts to read a manual, an FAQ or a Help page now and again. Whatever you know about a piece of software you’d be surprised what you can find out by going back over some instructions, maybe with a specific task in mind. My task was to create a number of templates for a WordPress-based website. Each template differed slightly from the other and would be used for pages in different categories.

So in WordPress it’s common to work with one theme or layout, with the front page possibly showing a newsfeed and then some other “pages” displaying less time-dependent content. So you might add a differing layout to the index and page elements of the theme. But then it’s possible to add other themed pages. reading the WordPress Codex page on Pages – http://codex.wordpress.org/Pages a useful tip is to add a couple of lines of code at the top of the file:

<?php
/*
Template Name: TemplateFile
*/
?>

Where TemplateFile is the name of your template. Add some other code and formatting such as the content, then the magic. Go into Pages > Add New and there’s now an option in Page Attributes for a Template in the dropdown list.

Project Details

Other Recent Projects

Ecommerce events website built with Joomla

Find out More

Joomla Gigs Listing Website

Find out More

Portfolio: Wellbeing Promise WordPress website

Find out More