I would like to show the total category count for that category under Add Sub Category (before collapse/expand all links) button on the left side.

Total category count should consider subcategories also. e.g. if I m on Default Category(Root category) then it should cover from What's New to Fitness Membership but not Gear(as this is not children) while calculating.

For category count, using the below function which is working fine at the moment but I do not know how to add that dynamic text under "Add Sub Category".

$childrenCategories = $this->getChildCategories($category);

Here $category would object.

enter image description here

  • Your question is improper. Please explain it in properly so we can understand easily and help you by giving you answer. – KKR Jul 16 at 5:37

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Browse other questions tagged or ask your own question.