a.niedermann Posted May 4, 2007 Share Posted May 4, 2007 Hey! I made one unique page for one of the products in my shop. And added a link to that page in categories.php. Now I have the problem of a double entry. Once the entry of the categories string and once the link I inserted. How can I manage, that the categories.php does not display this specific category id (the categories links which it creates automatically) without deleting the category? Thanks for help!! Andreas Link to comment Share on other sites More sharing options...
oschellas Posted May 4, 2007 Share Posted May 4, 2007 In includes/boxes/categories.php you could alter the $categories_query by adding and c.categories_id != 21 In the above example 21 is the id of the category I want to hide. Note that if you change your category structure in the future, you would have to check if 21 is still the id of the category you want to hide... Link to comment Share on other sites More sharing options...
a.niedermann Posted May 4, 2007 Author Share Posted May 4, 2007 thanks for your help! since I have no idea of php, could you please tell me where exactely I have to insert this code?? Thanks! Link to comment Share on other sites More sharing options...
oschellas Posted May 4, 2007 Share Posted May 4, 2007 Around line 73 $categories_query = tep_db_query("select c.categories_id, cd.categories_name, c.parent_id from " . TABLE_CATEGORIES . " c, " . TABLE_CATEGORIES_DESCRIPTION . " cd where c.parent_id = '0' and c.categories_id = cd.categories_id and c.categories_id != 21 and cd.language_id='" . (int)$languages_id ."' order by sort_order, cd.categories_name"); Around line 99 $categories_query = tep_db_query("select c.categories_id, cd.categories_name, c.parent_id from " . TABLE_CATEGORIES . " c, " . TABLE_CATEGORIES_DESCRIPTION . " cd where c.parent_id = '" . (int)$value . "' and c.categories_id = cd.categories_id and c.categories_id != 21 and cd.language_id='" . (int)$languages_id ."' order by sort_order, cd.categories_name"); Note: replace 21 by your category id Link to comment Share on other sites More sharing options...
a.niedermann Posted May 4, 2007 Author Share Posted May 4, 2007 WORKS GREAT!! THANKS A LOT!!! Link to comment Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.