Wednesday 28 May 2014

Magento Reindex Programmatically

for($i=1;$i<=9;$i++){
    Mage::getModel('index/process')->load($i)->reindexEverything();
 }

 // where I is

 1 = Product Attributes
 2 = Product Attributes
 3 = Catalog URL Rewrites
 4 = Product Flat Data
 5 = Category Flat Data
 6 = Category Products
 7 = Catalog Search Index
 8 = Tag Aggregation Data
 9 = Stock Status

No comments:

Post a Comment