Unique sidebar per category?

March 2014 WordPress Theme
GK User
Tue Jan 13, 2015 6:36 pm
Hi there, I am hoping to have a unique sidebar for a category archive like this and also the single posts within it: https://demo.gavick.com/wordpress/news2/?cat=240 and then another unique sidebar for say this category archive and again all the posts within it. Basically I would like to create unique sidebars per category essentially. I have looked at the https://www.gavick.com/documentation/wo ... dget-rules but there does not seem to be the option to have it completing unique to a sidebar. Is the framework compatible with any plugin that handles custom sidebars? or is there another way around this. The reason I ask is of course I want sports advertising on the advertising category and Liefstyle adverts on the sidebar of the lifestyle category etc etc.

Thanks in advance.
User avatar
Expert Boarder

GK User
Tue Jan 13, 2015 10:32 pm
Hi,

The easiest solution are widget rules. You can use the same sidebar i.e. Siebar Right, but i.e. you have 5 categories, so you should add 5 widgets (i.e. text widgets with your advert img) and using widget rules category you can display the first widget only on the first category, second will be displayed ONLY on the second etc.
category widget rules display widgets on the selected category and all posts within it.
User avatar
Moderator

GK User
Wed Jan 14, 2015 12:58 am
@Piotr thanks for the update here. This tends to get a little messy when you have alot of categories and a unique sidebar per category and its posts but il give it a try. can I ask if there is a way to make the leaderboard unique per category? For example using a functions.php if statement and using a hook here? Thanks
User avatar
Expert Boarder

GK User
Wed Jan 14, 2015 10:52 am
Could you please provide more details regarding leaderboard? or provide a screenshot becaue I'm not sure which element do you mean.
User avatar
Moderator

GK User
Wed Jan 14, 2015 5:38 pm
Sorry for not clarifying here. I am referring to the widget area called "Banner Top" in this theme which is really the place right at the top of the website on the right. The Ad space that says "leaderboard" on it in the top right of the demo here: https://www.gavick.com/demo/wordpress/news2/

Thanks
User avatar
Expert Boarder

GK User
Thu Jan 15, 2015 9:05 am
Sure, it's "Banner Top" widget area, so you can use the same solution with widget rules (add more widgets with different images and assign them to proper categories).
User avatar
Moderator

GK User
Thu Jan 15, 2015 10:02 am
Ah I see, ok this makes some sense now. thank you for this following up and the extra information as it has helped me and I am sure others also who might be newbies to the gavick framework here. Thanks
User avatar
Expert Boarder


cron