Jump to content
  • Checkout
  • Login
  • Get in touch

osCommerce

The e-commerce.

Hide a category and its subcategories from the menu


Psytanium

Recommended Posts

is there a way to hide a category and its subcategories from the bm_categories.php ?

 

This is what i tried:

if ($tree[$counter]['path'] == '30') {
		 $categories_string .= '<li '.$kk.' class="htooltip" style="display:none;">';
		$categories_string .= '<div class="div_2">';
	  }else{
	  $categories_string .= '<li '.$kk.' class="htooltip">';
		$categories_string .= '<div class="div_2">';
	  }

it helped me hide the category ID 30, but the menu is still showing its subcategories.

any hints please ?

Link to comment
Share on other sites

Hi

 

exclude the category concerned from the two $categories_query in bm_categories: ....where c.parent_id = '0' and c.categories_id = cd.categories_id and c.categories_id != '30'......

But with that the exluded categories are NOT inactive, i.e. with the direct input of the path in your browser you can call them on! To set certain categories completly inactive there's a contrib - if I remember well "Enable/Disable Categories".

 

J.J

Link to comment
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...