All about Magento E-commerce Store.......MagentoForum: product edit warning
Showing posts with label product edit warning. Show all posts
Showing posts with label product edit warning. Show all posts

Sunday, January 8, 2012

Magento: Product Edit Warning: Invalid argument supplied for foreach()


Scenario:
While editing product programatically from frontend. I was trying to change the status of the product with the following code:
Mage::getModel(‘catalog/product’)->load($product->getId())->setStatus(2)->save();