I would like to load Disabled products last or bottom in a product collection in a category listing. I want some thing like enabled products followed by disabled products in a product collection. is this possible in magento?
1 Answer
You could try:
$_collection = Mage::getModel('catalog/product')->getCollection()->setOrder('status','ASC')
or use a Custom Design --> Custom layout update for this category with something like:
<reference name="product_list">
<action method="setDefaultDirection"><dir>desc</dir></action>
</reference>
Which would include to have the status as the default product listing in the Display Settings of that category. You would need to make the status
-attribute to be available as Used for Sorting in Product Listing
before you can choose it as default sort order.