I’m attempting to write an application that uses Magento’s customer tables for its user data, while trying not to touch any of Magento’s code.
I found this thread, but Moshe’s suggestions do not seem to be working for me. I figure maybe it’s because the thread is almost a year old, and things may have changed too much in the current release, which as of now is 1.0.19870.4.
When I try the following suggestions from Moshe…
$customer = Mage::getModel('customer/customer')->setData(array(....))->save();
$id = $customer->getId();
I get the following uncaught exception:
Fatal error: Uncaught exception ‘Mage_Core_Model_Store_Exception’ in D:\workspace\public_html\store\app\code\core\Mage\Core\Model\App.php:1049
#0 D:\workspace\public_html\store\app\code\core\Mage\Core\Model\App.php(554): Mage_Core_Model_App->throwStoreException()
#1 D:\workspace\public_html\store\app\Mage.php(192): Mage_Core_Model_App->getStore(NULL) #2 D:\workspace\public_html\store\app\Mage.php(197): Mage::getStoreConfig(’web/url/use_sto...’, NULL)
#3 D:\workspace\public_html\store\app\code\core\Mage\Core\Controller\Request\Http.php(110): Mage::getStoreConfigFlag(’web/url/use_sto...’)
#4 D:\workspace\public_html\store\app\code\core\Mage\Core\Model\App.php(233): Mage_Core_Controller_Request_Http->setPathInfo()
#5 D:\workspace\public_html\store\app\Mage.php(404): Mage_Core_Model_App->init(’base’, ‘store’, Array)
#6 D:\PDT-Workspace\MissionTags\trunk\public_h in D:\workspace\public_html\store\app\code\core\Mage\Core\Model\App.php on line 1049
The exception happens as soon as “Mage::app(’base’)” is called. I’m running the code off of XAMPP under Windows, but I did try running it in my test Linux server, and I get the same errors.
Has anyone had any success in achieving external access to Magento’s customer tables? Any help would be very much appreciated!