fallback to db sessions if php's session extension is not loadable, atm. you get cryptic errors, bugs in the bugtracker and mails on the list ;-)

This commit is contained in:
Ralf Becker 2005-02-21 07:57:41 +00:00
parent c0bed5e88e
commit b313272616

View File

@ -1322,6 +1322,10 @@
if(empty($GLOBALS['phpgw_info']['server']['sessions_type']))
{
$GLOBALS['phpgw_info']['server']['sessions_type'] = 'db';
$GLOBALS['phpgw_info']['server']['sessions_type'] = 'php4'; // the more performant default
}
if ($GLOBALS['phpgw_info']['server']['sessions_type'] == 'php4' && !extension_loaded('session') && !@dl('session'))
{
$GLOBALS['phpgw_info']['server']['sessions_type'] = 'db'; // fallback if we have no php4 sessions support
}
include_once(PHPGW_API_INC.'/class.sessions_'.$GLOBALS['phpgw_info']['server']['sessions_type'].'.inc.php');