WordPress Adding Banners: This tutorial explains how to add a banner to a single page or set of pages in WordPress. This is particularly useful for those that have the desire to display a specific banner on a per page basis. For example, you might want one page to present a banner but do not want the banner to appear on your whole site. This can easily be accomplished in just a few steps, so let's get started.
How To: WordPress Adding Banners
WordPress Adding Banners to a single page:
- First, access your site via an ftp client and get a copy of your page.php (the file is located in the /wp-content/themes/your-theme directory)
- Open page.php using a text editor such as notepad++ and then add the following code to the top of the file:
<?php /* Template Name: Page Two */ ?>
- Add your banner code to the very top of the file and then save the file as page2.php
- Upload the saved file to your /wp-content/themes/your-theme directory.
- Log into the WordPress admin panel and select Manage -> Pages from the menu.
- From the list, select a page you would like to add the custom banner page to, then click edit.
- Under Advanced Options, you should see the Page Template dropdown menu.
- Select Page Two from the menu and then click the save button.
Now simply go view the page that you have just edited and you should see the new banner applied to that page. You can repeat this process multiple times to have different features available for specific pages