Skip to content

Instantly share code, notes, and snippets.

@Dan0sz Dan0sz/show-active-products.php Secret
Last active Oct 21, 2018

Embed
What would you like to do?
How to show only Visible/Active Products in Product Count
<?php
$collection = $_category->getProductCollection();
$collection->setVisibility(array(Mage_Catalog_Model_Product_Visibility::VISIBILITY_BOTH, Mage_Catalog_Model_Product_Visibility::VISIBILITY_IN_CATALOG));
$collection->addFieldToFilter('status',Mage_Catalog_Model_Product_Status::STATUS_ENABLED);
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.