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 » WordPress Themes » Atahualpa 3 Wordpress theme » Center area post/pages »

[SOLVED] Change Background Color based on Category Name


  #1  
Old Jul 16, 2010, 09:52 AM
tjwhitejr
 
4 posts · Apr 2010
I have set up a blog aggregator that has left (blue) and right (Red) blogs. http://www.olddominionblogs.com and I would like to have the background color to be either red or blue depending on the category of the blog. (Well, pink and light blue.) I have labeled the syndicated blogs with 2 categories each, one lefty or righty and the other category is the blog name.

Anyone know if this can be done? And if so, how?
  #2  
Old Jul 16, 2010, 11:12 AM
juggledad's Avatar
juggledad
 
23,687 posts · Mar 2009
OSX 10.11.5 WP 4.x Atahualpa(all) Safari, Firefox, Chrome
Do you mean you want the backrounnd of the post to be red or blue depending on the category?
You could do that with CSS
HTML Code:
.post.category-red {background: red;}
.post.category-blue {background: blue;}
__________________
"Tell me and I forget, teach me and I may remember, involve me and I learn." - Benjamin Franklin
Juggledad | Forum Moderator/Support
  #3  
Old Jul 16, 2010, 11:54 AM
tjwhitejr
 
4 posts · Apr 2010
Perfect. Small change to use correct category names and used hex colors to get readable shades.

Used:

.post.category-leftyblogs {background: #FFB6C1;}
.post.category-rightyblogs {background: #E0EEEE ;}

Thanks!

Bookmarks

Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes


Similar Threads
Thread Thread Starter Forum Replies Last Post
category-linked order based on category's hierarchy structure chipfedd Center area post/pages 4 Mar 1, 2013 12:44 PM
Change Footer background color Webbis Post-Kicker, -Byline & -Footer 3 Feb 5, 2010 11:49 AM
Why won't my background color change? timecatcher Atahualpa 3 Wordpress theme 3 Jul 28, 2009 06:25 AM
How do you change the background color? theyankeeblog Header configuration & styling 2 May 13, 2009 01:09 PM
How do I change the background color of the Kicker? whatsmytruth Post-Kicker, -Byline & -Footer 1 Apr 9, 2009 03:02 PM


All times are GMT -6. The time now is 10:23 AM.


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