Home Communication board WiKi Get Quote

Remove all of the Magento product

It is pretty easy to clean up the database with the following code:

$mp = Mage::getModel('catalog/product')
foreach($mp as $p) $p->delete();

Of course the following things should be included at the top of the script:

include $magento_dir.'/app/Mage.php';

PS: Please note the “admin” in the magento app, instead of the “default”. It's required, in other case you will receive the “Cannot complete this operation from non-admin area.” error.

Home About us Privacy statement Terms & Conditions Refund policy © 2007–2022 ArsCommunity