Hello, I’m new to the forum so forgive me if this was asked/answered in another place.
I’m trying to retrieve User information from Yii app in a separate PHP application. In other frameworks I was able to bootstrap the API, but not start the output process. I’m trying to do this in Yii, but it’s not working.
If I run these few lines in my external application:
// Yii variables
$yii = dirname(__FILE__) . '/../../../../yii-1.1.14/framework/yii.php';
$config = dirname(__FILE__) . '/../../../yiiusers/protected/config/main.php';
require_once($yii);
Yii::createWebApplication($config);
It gives me errors because Yii starts loading the site/index controller.
I got something similar with
Yii::createConsoleApplication()
;
Is there a way to do this?
Essentially, what I’m trying to do is access the Yii User variables and Session in an external app (on the same domain, so cookies are shared), and run database queries.
Thanks for any help.
-Wes