At some point we all misuse phrases and terms. In the website world, the terms “templates” and “themes” are often confused. Very often a WordPress template are considered as WordPress theme and vice verse. Well that is part right. WordPress theme is simply the way your complete blog looks and represents you or your business online i.e. your website. A template is the way for securing consistency in the look and feel of all the pages that you want to appear the same way. Templates takes into consideration font style, page design for example. However you can create individual templates for individual page appearances. WordPress page templates within a WordPress theme, can be used therefore change the look of the inner page(s) of a theme. So for instance, if you would like to have an author page, you can create that so that it is a little different than your other base pages. You would have one template for the author page and another for all remaining base pages. A common desire is to have a way to make a different design on certain pages with my themes. This is where I can assist to create additional WordPress page templates within your overall theme. They are really easy to create and build. Here’s how:
What you have to do first.
Well probably the easiest to create, and unknown to many, is called a snarfer file. A snarfer file is a file that you add to your theme folder so that you can use it as a template. Let me give you a scenario. You would like to have a template specifically for your ‘about’ page. That way you can add other elements into the page that your other pages don’t have. Or maybe you don’t want comments for this page. Simply go to the theme folder on your server and create a file named About.php. The first thing that you have to do with this file is add the following code to the top:
Template Name: //What you want the template name to be
Next you have to add the rest of the code to create the template. One of the easiest things to do is just add all the code from the Page.php file and change it as you need. That way it won’t look different from your other pages but you can still add and delete what ever you want, hence creating a slightly different template for your desired page. After you have completed the customization of the new template file all you have to do is set the page to use the template page.
To finish your template page login to WordPress and go to your newly created page. Now go to the right side of the page and you should see a place that says template with a drop down menu. Drop that down and your template name should be right there. Select it and save and you are done.