I am trying to create a product progrmatically in magento
require_once('./app/Mage.php');
Mage::app()->setCurrentStore(Mage::getModel('core/store')->load(Mage_Core_Model_App::ADMIN_STORE_ID));
$product = Mage::getModel('catalog/product');
$product->setSku("ABC123") // OK
->setName("Type 7 Widget") // NOK
->setDescription("This widget will give you years of trouble-free widgeting.") // NOK
->setShortDescription("High-end widget.") // NOK
->setPrice(70.50) // OK
->setTypeId('simple') // OK
->setAttributeSetId('14') // need to look this up // OK
->setCategoryIds("3,7") // need to look these up // OK
->setWeight(1.0) // OK
->setTaxClassId(1) //taxable goods // ?
->setVisibility(4) // catalog, search // NOK
->setStatus(Mage_Catalog_Model_Product_Status::STATUS_ENABLED); // enabled // NOK
$product->setWebsiteIds(array(Mage::app()->getStore(true)->getWebsite()->getId()));
$product->save();
?>
here is my code . it is giving me error Fatal error: Class 'Mage_Core_Model‌​_App'
Can anybody tell me wh
$product->setStockData(array('is_in_stock' => 1, 'manage_stock' => 1));