adsense

How to Create Custom Post Backgrounds on WordPress





Styling Your Backgrounds
1. Log in to your WordPress admin control panel. Click 'Appearance' then click 'Editor.' This area allows you to edit the HTML files that make up the blog. Click 'style.css' at the bottom of the list on the right. Scroll through the code and locate #content. Copy all the code starting from and including this line, to the closing } bracket.
2. Start a new line and paste this code into it. Add in new CSS code to display the background you want. If you want a color, type the following code:background-color: #FFFFFF;Replace 'FFFFFF' with the hex code for the color you want. If you want a background image, add the following code:background-image:URL('http://locationofimage.com/image.gif');Replace the URL above with the location of your image.

3. Give the section a new name, for example #contentblue. Repeat this process for each different post background that you require, and click 'Update File' when done.
Creating Custom Post Templates
4. Click 'single.php' from the list on the right. Copy all the code that appears in the middle. Load up a text editor such as Notepad or Textedit, and paste all the code into it. Add the following code at the very top of the file:
Replace 'ContentBlue' with one of the names you created in the stylesheet, and save the file as 'contentblue.php' -- again, replacing the name to the one you used earlier.
5. Repeat this process, creating a new file for every custom post background that you need.
6. Log in to your FTP account and go to 'wp-content,' 'themes,' then load up the folder of the theme you are using. Upload all your custom post templates to this folder.
Adding the Custom Background to a Post
7. Return to the WordPress admin area. Click 'Plugins,' then 'Add New,' and search for 'Single Post Template' using the search field that appears.
8. Locate 'Single Post Plugin' in the search results and click 'Install Now.' After the plugin has installed, click 'Activate Plugin.'
9. Click 'Posts' on the main menu bar, then click on the post that you want to customize. Find the new menu 'Single Post Templates,' and select the custom template you want from the drop-down menu. Click 'Update Post.'
10. Repeat this process for all the posts you want to customize.

Comments

0 Responses to "How to Create Custom Post Backgrounds on WordPress"

Post a Comment

Popular Posts

About