Show only specific categories in k2 filter

More
6 years 2 months ago - 6 years 2 months ago #41007 by pollmannsc
Hi,

how can I show only specific k2 categories in the filter?

I want to add my k2 items with marker in the category "Locations" and want to show only all sub-categories from "Locations" in the filter.

Is this possible? Thx
Last edit: 6 years 2 months ago by pollmannsc.

Please Log in or Create an account to join the conversation.

More
6 years 2 months ago #41008 by nordmograph
Hello,
Well , you'll have to edit the traverse_tree_down function in the k2.php of the plg_geommunity_k2 plugin.

- Need help? Post the URL of the related page (eventualy as confidential info), it will help solve your issue faster.
- An error, notice or warning? report the exact message including the line number
- If you get a white page , enable error reporting and / or check your server error logs.
The following user(s) said Thank You: pollmannsc

Please Log in or Create an account to join the conversation.

More
6 years 2 months ago #41020 by pollmannsc
Thank you!

I've made the following changes that work for me:
Code:
function onGetFilter() { ob_start(); $this->traverse_tree_down( 67, 0 ); $output = ob_get_clean(); return $output; }

Where "67" is my "Locations" category with my subcategories for the filter module.

Please Log in or Create an account to join the conversation.

Time to create page: 0.318 seconds
Powered by Kunena Forum
Disclaimer: Nordmograph is not affiliated with or endorsed by The Joomla! Project™. Any products and services provided through this site are not supported or warrantied by The Joomla! Project or Open Source Matters, Inc. Use of the Joomla!® name, symbol, logo and related trademarks is permitted under a limited license granted by Open Source Matters, Inc.