[dev] hooks: prefs & conf loading problem

Hans Lellelid hans at appliedsec.com
Wed Jan 8 17:12:05 PST 2003


Hi Chuck,

Thanks for making that change.  One thing I notice in the change you 
made, however, is that you're loading the app's config before the 
session starting block.  -- it would seem that this needs the _horde_ 
$conf array, but truthfully I haven't tested this out yet. :-)

So, code block in question is:

             /* Import Horde's configuration values. */
            $this->importConfig('horde');

            /* Import this application's configuration values. */
            $this->importConfig($app);

            /* Start the session if this is the first application to
               be loaded. */
            if (!isset($session_started)) {
                global $conf;

                $session_started = true;
                ini_set('session.use_trans_sid', 0);
                session_set_cookie_params($conf['session']['timeout'], 
$conf['cookie']['path'], $conf['cookie']['domain']);
                session_cache_limiter($conf['session']['cache_limiter']);
                session_name(urlencode($conf['session']['name']));
                Horde::setupSessionHandler();
                @session_start();
            }

I was thinking that the $this->importConfig($app) could go after the 
if(!isset($session_started)) {...} block since the $conf needed by that 
block looks like the global $conf.

Sorry :-)  Would you prefer I just find out what works & submit a diff?

Thanks,
Hans

>  
>
-------------- next part --------------
A non-text attachment was scrubbed...
Name: smime.p7s
Type: application/x-pkcs7-signature
Size: 4461 bytes
Desc: S/MIME Cryptographic Signature
Url : http://lists.horde.org/archives/dev/attachments/20030108/700c9b0c/smime.bin


More information about the dev mailing list