Wordpress Themes - WP Forum at BFA
Click here to register or to donate.
Auto self-registration is not available here - far too many spammers. This forum has many, many backlinks and because of that there is an intense desire among spammers to drop their links here.

Wordpress Themes - WP Forum at BFA » Forum Usage » Forum How-To »

[SOLVED] Styling the homepage differently than the single page


  #1  
Old Mar 24, 2011, 02:29 AM
winsila
 
2 posts · Dec 2010
How do I apply a styling that affects only the homepage elements and not the single page? For instance, I want to add a border above and below a post container in the homepage but I don't the borders to appear in the singe post view. How do I do that?
  #2  
Old Mar 24, 2011, 05:18 AM
juggledad's Avatar
juggledad
 
23,671 posts · Mar 2009
OSX 10.11.5 WP 4.x Atahualpa(all) Safari, Firefox, Chrome
you will need to add CSS Selectors and CSS rules to do the styling. You can prefix any selector with 'body.home' so to have a border around a post on the home page you would use
HTML Code:
body.home .post {border: solid 2px red;}
A great tool to use if you don't already, is FireBug in FireFox so you can see the existing CSS for an element in the HTML
__________________
"Tell me and I forget, teach me and I may remember, involve me and I learn." - Benjamin Franklin
Juggledad | Forum Moderator/Support
  #3  
Old Mar 24, 2011, 06:10 AM
winsila
 
2 posts · Dec 2010
Thanks Juggledad. I do use FireBug but I was not aware of the body.home stuff. Thanks again.

Bookmarks

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes


Similar Threads
Thread Thread Starter Forum Replies Last Post
Style each post differently by category lisyan Center area post/pages 15 Jan 21, 2011 07:03 PM
Permalink in single post and single page anup Center area post/pages 0 Jul 15, 2010 09:46 AM
KICKER: Homepage %category-linked"% causes right sidebars to disappear from homepage Jazoja Post-Kicker, -Byline & -Footer 2 Jun 23, 2010 05:32 PM
Widgets page and plug ins add page not working, and displaying differently shamrock 2000 Sidebars & Widgets 10 Feb 16, 2010 04:19 PM
[SOLVED] Body styling only in homepage peking Header configuration & styling 2 Oct 3, 2009 05:11 PM


All times are GMT -6. The time now is 08:16 PM.


Powered by vBulletin® Copyright ©2000 - 2018, Jelsoft Enterprises Ltd.