Jump to content

Subcategories in Prestashop 1.4.0


Recommended Posts

Hi,

I just want to show the other subcategories when you are in a subcategory a page.

In the last version I have changed in the category.php line 50:

$subCategories = $category->getSubCategories(intval($cookie->id_lang));



to:

$subCategories = $category->getSubCategories(intval($cookie->id_lang));
if (sizeof($subCategories) == 0 AND intval($category->id_parent) > 1)
{
  $parentCategory = new Category(intval($category->id_parent), intval($cookie->id_lang));
  $subCategories = $parentCategory->getSubCategories(intval($cookie->id_lang));
}




Now in this new Prestashop version (1.4.0), I can't do this...

What I must change to obtain the same result?

Thanks in advance!

Link to comment
Share on other sites

  • 4 months later...

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...