Magento product report resource collection allows you to get most popular products based on different options.
functions we will use: addOrderedQty, setOrder
Let's load this resource collection first like this:
More»
Here are the list of free magento templates / themes demo and download where available. Suggest us more templates to grow this list.
More»
In Magento you can load your model with getModel. You can optionally pass parameters to the model class constructor. All you need to do is:
Mage::getModel('model_class', 'arguments_as_array_if_any');
For example: I want to load Data.php model from: https://github.com/dbashyal/Magento-General-Module-Extension
More»