Connect to the Magento database

This function create the Mage object.

require_once '../app/Mage.php';
ini_set('display_errors', 1);
Mage::app('admin');
Mage::setIsDeveloperMode(true);
Mage::app()->setCurrentStore(Mage_Core_Model_App::ADMIN_STORE_ID);

Share this Tutorial