Wordpress Themes - WP Forum at BFA

Wordpress Themes - WP Forum at BFA (http://forum.bytesforall.com/index.php)
-   Post-Kicker, -Byline & -Footer (http://forum.bytesforall.com/forumdisplay.php?f=17)
-   -   Different BG-Color for different Categories?? (http://forum.bytesforall.com/showthread.php?t=4859)

hdwolle Dec 13, 2009 02:01 PM

Different BG-Color for different Categories??
 
Hello together,

I hope you have great christmas time?

I have a very difficult question.

It is possible to give each category an other background color?

I hope that someone can help me.

Best Wishes,

Markus

juggledad Dec 13, 2009 05:01 PM

where do you want to change the color? in the menu, the backgrond of a post of that category, on a category page?

hdwolle Dec 13, 2009 07:32 PM

I want to change it on the "summary" site of all posts.

So that the visitors see with each background-color in which category the post is.

And also I want to make the navigation for the categories in the same colors (as a legend).

juggledad Dec 14, 2009 06:51 AM

what if a post is in mutiple categories?
and by 'summaries' do you mean the 'excerpts'? ie say you have one full post on the home page and 5 excerpts, you want the excerpts to be colored based on the category?

background or just the text color or both?

can you point out what you want on your site? detailed example

hdwolle Dec 14, 2009 07:16 AM

I will show it with a little grafic example and I hope it's good to understand.

http://www.imgbox.de/users/public/images/u23265n93.jpg

The image shows the frontpage with all actual posts and each post should have another background color.

And on the left sidebar the navigation have to be in the same color as the post backgrounds.

I hope it is clear enough.

juggledad Dec 14, 2009 07:54 AM

all you need to do is use css inserts (ATO->Add HMTL/CSS Inserts->CSS Insert) like this
HTML Code:

div.category-red-wine {background: #red;}
div.category-books {background: #blue;}
div.category-white-wine {background: #yellow;}

the name will be 'category-' plus teh category slug (dashboard->Posts->Categories)
the last insert will take prescidence, so if you had a post with the category 'books' and 'white wine' then it would be YELLOW. If you had the CSS in this order
HTML Code:

div.category-red-wine {background: #red;}
div.category-white-wine {background: #yellow;}
div.category-books {background: #blue;}

then the post would be BLUE

hdwolle Dec 14, 2009 08:16 AM

Thanks. I will try it.

And I can try to modify it like I want e.g. round corners and so on.

I will post it here when I'm ready with the changes.


All times are GMT -6. The time now is 07:41 PM.

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