[dev] Fwd: Re: Horde api not working when calling from a function

kshema kshemav at aztecsoft.com
Wed Mar 14 05:06:18 UTC 2007


I have modified the code like this..
include 'C:\Program Files\Apache
Group\Apache\htdocs\horde\imp\lib\Fetchmail.php';
@define('AUTH_HANDLER', true);
@define('HORDE_BASE', 'C:\Program Files\Apache Group\Apache\htdocs\horde');
require_once HORDE_BASE . '/lib/core.php';
$registry = &Registry::singleton();
global $conf;
$auth = &Auth::singleton($conf['auth']['driver']);

But now i am getting an error like this,
A fatal error has occurred
imp is not configured in the Horde Registry.
Details have been logged for the administrator.


Michael Rubinsky wrote:
> 
> 
> 
> 
> -- Forwarded Message --
> 
> More than likely core.php has already been included so $conf is defined
> outside the scope of your function and you'll need to bring it in scope.
> 
> Kshema Vargheese wrote on 3/13/07 2:33 am
> 
>>
>>I have written this code to a 
>>function inside a class.
>>
>>
>>
>>@define('AUTH_HANDLER', 
>>true);
>>
>>@define('HORDE_BASE', 
>>'C:\Program Files\Apache
>>Group\Apache\Dev\phpmvc
>>-base\WEB-INF\horde');
>>
>>require_once HORDE_BASE . 
>>'/lib/core.php';
>>
>>$registry 
>>&Registry::singleton();
>>
>>$auth 
>>&Auth::singleton($conf['auth
>>']['driver']);
>>
>>
>>
>>When I am calling this 
>>function I am getting error 
>>like "Undefined
>>variable: conf".
>>
>>
>>
>>But working fine when using 
>>directly without using class.
>>
>>
>>
>>
>>The information contained 
>>in, or attached to, this e-
>>mail, contains confidential 
>>information and is intended 
>>solely for the use of the 
>>individual or entity to whom 
>>they are addressed and is 
>>subject to legal privilege. If 
>>you have received this e-
>>mail in error you should 
>>notify the sender 
>>immediately by reply e-
>>mail, delete the message 
>>from your system and 
>>notify your system 
>>manager. Please do not copy 
>>it for any purpose, or 
>>disclose its contents to any 
> 
> Thanks,
> Mike
> 
> ---
> This message sent using my Treo Smartphone.
> 
> 
> -- 
> Horde developers mailing list - Join the hunt: http://horde.org/bounties/
> Frequently Asked Questions: http://horde.org/faq/
> To unsubscribe, mail: dev-unsubscribe at lists.horde.org
> 
> 

-- 
View this message in context: http://www.nabble.com/Fwd%3A-Re%3A-Horde-api-not-working-when-calling-from-a-function-tf3396993.html#a9468610
Sent from the Horde - Dev mailing list archive at Nabble.com.



More information about the dev mailing list