indakno 0 Report post Posted July 18, 2012 I have the feature section showing on the Category page. How do I get the feature to show only the features of that particular category? Share this post Link to post Share on other sites
Danny+ 1,327 Report post Posted July 18, 2012 Hi Indakno, This isn't currently possible and has been added to our tracker as a feature request. Please search our forums, before posting! Share this post Link to post Share on other sites
indakno 0 Report post Posted July 18, 2012 Thank You. Please keep me posted. Share this post Link to post Share on other sites
Simon 248 Report post Posted July 18, 2012 Actually it is possible, all PageLines options are filterable! This is a very powerful filter ;) So the option in question is [b]feature_category[/b] so we have to use a filter called [b]ploption_feature_category[/b] which will overide the category you have set. Then in the filter we will just feed it with whatever the current category is. Here is the code, add it to the customize plugin functions.php [code]add_filter( 'ploption_feature_category', 'make_cat_features', 10, 2); function make_cat_features( $key, $o) { global $wp_query; $category = $wp_query->query_vars['cat']; return $category; }[/code] Share this post Link to post Share on other sites
indakno 0 Report post Posted July 26, 2012 So, how does this work for each different category page? I have about 11 or 13 different categories. Or does it automatically pull the correct category features? Thanks for your help. Share this post Link to post Share on other sites
Rob 547 Report post Posted July 26, 2012 Simon's code picks up the features from the category where the slider appears, so in reply to your last question, yes it does. In response to the first... trust that if Simon says... it works. After all, he wrote most of it. Former PageLines Moderator, Food Expert and Raconteur Share this post Link to post Share on other sites
indakno 0 Report post Posted July 26, 2012 Ok. I will try it and see how it goes and let you guys know. Thanks! Share this post Link to post Share on other sites
indakno 0 Report post Posted July 26, 2012 IT WORKED!!!!! Thanks guys. Share this post Link to post Share on other sites