I've been trying to get a different banner for each individual category, but I cannot seem to get this to work properly.
If I go to a category and I enter an image, it doesn't change the banner, but will simply add another image below the banner. To make thing worse is that the category image will fall behind any images at the top of an entry.
Is there an easy way to have a different banner for each category?
If I remember correctly, I previously modified the index.tpl of my theme and that is how I got a new banner, but what I'm actually trying to achieve is a new banner for each category.
Hope everything I've written makes sense.
I'll attach some screen shots for the sake of clarity.
In this I have already changed the banner.
Here I have tried to add an image for the category, but the end result is nowhere near what I desired.
Category images or banners
Re: Category images or banners
That's meant to be used for a category icon actually. Something to indicate the category of an entry visually, usually within the entry.hdiaz36 wrote:If I go to a category and I enter an image, it doesn't change the banner
Phew, define "easy".hdiaz36 wrote:Is there an easy way to have a different banner for each category?
We have the event plugin "Properties/Templates of categories" which makes it possible to assign different templates to a category. You could assign the same template to each category, but with a different banner. This would be much easier if your template supports a header image from the media db, which I take it is not the case right now?
My personal experience with this plugin is that it is kind of complicated to use and prone to error. Everyone's mileage may vary.
You could also hack your template to use different banner images for various categories, but that is kind of difficult to implement, I guess.
YL
-
- Core Developer
- Posts: 30022
- Joined: Tue Sep 16, 2003 9:45 pm
- Location: Cologne, Germany
- Contact:
Re: Category images or banners
Hi!
Maybe the easiest way is inside your index.tpl:
on the banner, and then use CSS to create a class for serendipity_banner1, serendipity_banner4 etc. (the number corresponds to the number of your category).
HTH,
Garvin
Maybe the easiest way is inside your index.tpl:
Code: Select all
<div class="serendipity_banner{$category}">
HTH,
Garvin
# Garvin Hicking (s9y Developer)
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
# Did I help you? Consider making me happy: http://wishes.garv.in/
# or use my PayPal account "paypal {at} supergarv (dot) de"
# My "other" hobby: http://flickr.garv.in/
-
- Regular
- Posts: 3652
- Joined: Mon Feb 13, 2006 2:40 am
- Location: Chicago, IL, USA
- Contact: