one solution to your problem using jQuery( put this code in functions.php
)
<?php
add_action('wp_footer','ravs_browse_menu');
function ravs_browse_menu(){
if(isset($_GET['cat']) && $_GET['cat'] !=''){
?>
<script>
jQuery(document).ready(function(){
jQuery('#menu-item-299').addClass('current-menu-item');
});
</script>
<?php
}
}
?>
Related Posts:
- How to create an automatic MultiColoumn MegaMenu with Categories WordPress
- Preventing index.php?category_name=something from redirecting
- Make all subcategories use the template of its category parent?
- Custom Nav Walker menu – Display category count
- Different templates for parent and children categories/taxonomies
- Reflect nested categories in appearance > menus
- Category menu item and its last 10 posts as sub-menu
- Display only deepest category on a single post?
- Create a full width responsive header image per page
- How do I set a specific template for sub-categories?
- Remove “Category Archives: title” at the top of a category page [duplicate]
- Exclude a category from the filed under list only on some templates
- Is there a function to cause empty categories not to show in menus?
- Create single.php for specific category by category id
- Assign different category colours to different categories in the main menu
- Keep active class in post page
- Auto add pages to category menu
- How to show empty category in admin menus search
- Add custom taxonomy terms to WordPress menu dynamically & append #slug to url
- Display WooCommerce product categories in a 4 columns custom menu [closed]
- is_archive() content being shown instead of is_category()
- How to override Category rendering mechanism
- How to control template resolution if both Author and Category filter in place?
- Which php file lists all the post of a category
- Automatically add product_categories to nav_menu
- Apply custom category template to subcategories
- Hide post meta data on a specific category
- Add Product categories to WordPress menu without losing hierarchy
- Custom Category/Subcategory structure
- Add a specific category at a specific place to the menu that uses wp_list_pages
- Custom page for WooCommerce’s /product-category/
- Multiple menu items highlighted
- Code to pull in a PHP file named after the category ID
- wp_nav_menu not highlighting the current category when viewing a single post
- Show recent posts in menu?
- Exclude category from Tag Template
- Different excerpt styles per category, but chronological
- Show Different Custom Menu on Different Category Pages
- How to make a Thumbnails Mosaic
- Are Category or Tag Archive Pages Possible?
- Open subcategories in submenu on click in primary menu
- How to add Categories to the top menu of the website?
- Implementing a tricky wordpress menu (nested categories + thumbnails)
- Possible to make a subdirectory that loops through a single category?
- Need Category RSS Feed that shows all posts
- WooCommerce IF statements not working
- Looking for the best solution to build this Blog structure? Picture attached?
- Nav menu category links not showing
- Set a them for all subset of category
- How to display only posts assigned to a particular, isolated, subcategory
- Show number of articles in menu
- How to show only one category in breadcrumb navigation
- Automatically adding categories and authors in custom menu?
- Hard coded main navigation
- Category location styling
- Archive.php filtered by pre-determined category
- one category template for multiple categories
- Class active for Archive link – looped out
- Hide woocommerce category name from specific pages
- Hide woocommerce category name from specific pages
- Different templates for different category tags
- The default code for “posts_nav_link” on category.php isn’t working
- Only one post is showing on category page, why?
- Updating category template to change how subcategories display
- Menus don’t work after 4.4 [closed]
- category permalinks
- Create menu / submenu from category subcategory and posts
- Categories overview that links to page displaying posts
- How can I get categories IDs if multiple categories requested via URI?
- wp_list_categories in in nav_menu
- Different menu navigation per category
- WP admin broken. Not saving catgories or adding categories to menu
- Creating Category Specific menus
- Style category link depending on category ID
- Custom Walker for wp_list_categories
- Category template to show different categories based on parent
- Does “show_option_all” in wp_list_categories do anything?
- How can I improve this taxonomy treating approach?
- Sub category templates
- Inside a loop, how to change CSS class based on category name?
- Custom taxonomy template for categories
- Redirect to another page using contact form 7? [closed]
- How to insert category list into post creation page, and retrieve chosen categories?
- Why do I have stray bullet from
- Create menu locations for each category in wordpress
- Limit number of posts on a custom category template – breaking pagination
- How to add custom color fields to the category edit page?
- Building Menu from Woocommerce Product Categories
- Hooking to walker_nav_menu_start_el to insert list of subpages
- Show subcategories on a parent category page
- Admin: Navigation Menus do not show empty categories/taxonomies in the list’s search tab
- Give Children Unique ID’s
- Change div background acording to the selected category
- How can I display the number of post associated to a category in Twig/Timber WordPress? [closed]
- WordPress list categories dropdown with parent-child relation and child under it’s parent
- Is it possible to have a template that works on multiple categories where the link address contains the specific category?
- List a maximum of ‘x’ product categories with qty of ‘y’ in each column
- Custom template for sub-sub-categories
- Different CSS class by category
- What Must to Display the “mysite.com/category” URL?