mirror of
https://github.com/Dolibarr/dolibarr.git
synced 2025-02-20 13:46:52 +01:00
New: Can set session timeout.
This commit is contained in:
parent
db74ae5c7e
commit
80ca284557
|
|
@ -117,7 +117,7 @@ foreach ($eventstolog as $key => $arr)
|
|||
print '<td>';
|
||||
$key='MAIN_AGENDA_ACTIONAUTO_'.$arr['id'];
|
||||
$value=$conf->global->$key;
|
||||
print '<input type="checkbox" name="'.$key.'" value="1"'.($value?' checked="true"':'').'>';
|
||||
print '<input '.$bc[$var].' type="checkbox" name="'.$key.'" value="1"'.($value?' checked="true"':'').'>';
|
||||
print '</td></tr>'."\n";
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -17,11 +17,11 @@
|
|||
*/
|
||||
|
||||
/**
|
||||
\file htdocs/admin/events.php
|
||||
\ingroup core
|
||||
\brief Log event setup page
|
||||
\version $Id$
|
||||
*/
|
||||
* \file htdocs/admin/events.php
|
||||
* \ingroup core
|
||||
* \brief Log event setup page
|
||||
* \version $Id$
|
||||
*/
|
||||
|
||||
require("./pre.inc.php");
|
||||
require_once(DOL_DOCUMENT_ROOT."/lib/admin.lib.php");
|
||||
|
|
@ -133,7 +133,7 @@ foreach ($eventstolog as $key => $arr)
|
|||
print '<td>';
|
||||
$key='MAIN_LOGEVENTS_'.$arr['id'];
|
||||
$value=$conf->global->$key;
|
||||
print '<input type="checkbox" name="'.$key.'" value="1"'.($value?' checked="true"':'').'>';
|
||||
print '<input '.$bc[$var].' type="checkbox" name="'.$key.'" value="1"'.($value?' checked="true"':'').'>';
|
||||
print '</td></tr>'."\n";
|
||||
}
|
||||
}
|
||||
|
|
|
|||
|
|
@ -17,11 +17,11 @@
|
|||
*/
|
||||
|
||||
/**
|
||||
\file htdocs/admin/security_other.php
|
||||
\ingroup core
|
||||
\brief Page de configuration du module s<EFBFBD>curit<EFBFBD> autre
|
||||
\version $Id$
|
||||
*/
|
||||
* \file htdocs/admin/security_other.php
|
||||
* \ingroup core
|
||||
* \brief Page de configuration du module s<EFBFBD>curit<EFBFBD> autre
|
||||
* \version $Id$
|
||||
*/
|
||||
|
||||
require("./pre.inc.php");
|
||||
require_once(DOL_DOCUMENT_ROOT."/lib/admin.lib.php");
|
||||
|
|
@ -62,6 +62,13 @@ else if ($_GET["action"] == 'disable_captcha')
|
|||
exit;
|
||||
}
|
||||
|
||||
if ($_GET["action"] == 'MAIN_SESSION_TIMEOUT')
|
||||
{
|
||||
dolibarr_set_const($db, "MAIN_SESSION_TIMEOUT", $_POST["MAIN_SESSION_TIMEOUT"]);
|
||||
Header("Location: security_other.php");
|
||||
exit;
|
||||
}
|
||||
|
||||
if ($_GET["action"] == 'activate_avscan')
|
||||
{
|
||||
dolibarr_set_const($db, "MAIN_USE_AVSCAN", '1');
|
||||
|
|
@ -99,7 +106,7 @@ $form = new Form($db);
|
|||
|
||||
print '<table width="100%" class="noborder">';
|
||||
print '<tr class="liste_titre">';
|
||||
print '<td>'.$langs->trans("Parameter").'</td>';
|
||||
print '<td colspan="2">'.$langs->trans("Parameter").'</td>';
|
||||
print '<td>'.$langs->trans("Value").'</td>';
|
||||
print '<td> </td>';
|
||||
print "</tr>\n";
|
||||
|
|
@ -107,7 +114,7 @@ print "</tr>\n";
|
|||
|
||||
print '<form action="'.$_SERVER["PHP_SELF"].'?action=set_main_upload_doc" method="POST">';
|
||||
print '<tr '.$bc[$var].'>';
|
||||
print '<td>'.$langs->trans("MaxSizeForUploadedFiles").'.';
|
||||
print '<td colspan="2">'.$langs->trans("MaxSizeForUploadedFiles").'.';
|
||||
$max=@ini_get('upload_max_filesize');
|
||||
if ($max) print ' '.$langs->trans("MustBeLowerThanPHPLimit",$max*1024,$langs->trans("Kb")).'.';
|
||||
else print ' '.$langs->trans("NoMaxSizeByPHPLimit").'.';
|
||||
|
|
@ -119,6 +126,22 @@ print '<td align="center">';
|
|||
print '<input type="submit" class="button" name="button" value="'.$langs->trans("Modify").'">';
|
||||
print '</td>';
|
||||
print '</tr></form>';
|
||||
|
||||
$var=!$var;
|
||||
if (empty($conf->global->MAIN_SESSION_TIMEOUT)) $conf->global->MAIN_SESSION_TIMEOUT=ini_get("session.gc_maxlifetime");
|
||||
print '<form action="'.$_SERVER["PHP_SELF"].'?action=MAIN_SESSION_TIMEOUT" method="POST">';
|
||||
print '<tr '.$bc[$var].'>';
|
||||
print '<td>'.$langs->trans("SessionTimeOut").'</td><td align="right">';
|
||||
print $form->textwithhelp('',$langs->trans("SessionExplanation",ini_get("session.gc_probability"),ini_get("session.gc_divisor")));
|
||||
print '</td>';
|
||||
print '<td nowrap="1">';
|
||||
print '<input class="flat" name="MAIN_SESSION_TIMEOUT" type="text" size="6" value="'.$conf->global->MAIN_SESSION_TIMEOUT.'"> '.$langs->trans("seconds");
|
||||
print '</td>';
|
||||
print '<td align="center">';
|
||||
print '<input type="submit" class="button" name="button" value="'.$langs->trans("Modify").'">';
|
||||
print '</td>';
|
||||
print '</tr></form>';
|
||||
|
||||
print '</table>';
|
||||
|
||||
print '<br>';
|
||||
|
|
|
|||
|
|
@ -36,6 +36,8 @@ if (!$user->admin)
|
|||
/*
|
||||
* View
|
||||
*/
|
||||
|
||||
$form=new Form($db);
|
||||
|
||||
llxHeader();
|
||||
|
||||
|
|
@ -100,94 +102,24 @@ print '<br>';
|
|||
|
||||
$var=true;
|
||||
print '<table class="noborder" width="100%">';
|
||||
print '<tr class="liste_titre"><td>'.$langs->trans("Session").'</td><td>'.$langs->trans("Value").'</td></tr>'."\n";
|
||||
print '<tr class="liste_titre"><td>'.$langs->trans("Session").'</td><td colspan="2">'.$langs->trans("Value").'</td></tr>'."\n";
|
||||
$var=!$var;
|
||||
print "<tr ".$bc[$var]."><td width=\"300\">".$langs->trans("SessionId")."</td><td>".session_id()."</td></tr>\n";
|
||||
//$var=!$var;
|
||||
//print "<tr ".$bc[$var]."><td width=\"300\">".$langs->trans("CurrentSessionTimeOut")."</td><td>".ini_get('session.gc_maxlifetime').' '.$langs->trans("seconds")."</td></tr>\n";
|
||||
print "<tr ".$bc[$var]."><td width=\"300\">".$langs->trans("SessionId").'</td><td colspan="2">'.session_id()."</td></tr>\n";
|
||||
$var=!$var;
|
||||
print "<tr ".$bc[$var]."><td width=\"300\">".$langs->trans("CurrentTheme")."</td><td>".$conf->theme."</td></tr>\n";
|
||||
print "<tr ".$bc[$var]."><td width=\"300\">".$langs->trans("CurrentSessionTimeOut").'</td><td>'.ini_get('session.gc_maxlifetime').' '.$langs->trans("seconds");
|
||||
print '</td><td align="right">';
|
||||
print $form->textwithhelp('',$langs->trans("SessionExplanation",ini_get("session.gc_probability"),ini_get("session.gc_divisor")));
|
||||
print "</td></tr>\n";
|
||||
$var=!$var;
|
||||
print "<tr ".$bc[$var]."><td width=\"300\">".$langs->trans("CurrentTopMenuHandler")."</td><td>".$conf->top_menu."</td></tr>\n";
|
||||
print "<tr ".$bc[$var]."><td width=\"300\">".$langs->trans("CurrentTheme").'</td><td colspan="2">'.$conf->theme."</td></tr>\n";
|
||||
$var=!$var;
|
||||
print "<tr ".$bc[$var]."><td width=\"300\">".$langs->trans("CurrentLeftMenuHandler")."</td><td>".$conf->left_menu."</td></tr>\n";
|
||||
print "<tr ".$bc[$var]."><td width=\"300\">".$langs->trans("CurrentTopMenuHandler").'</td><td colspan="2">'.$conf->top_menu."</td></tr>\n";
|
||||
$var=!$var;
|
||||
print "<tr ".$bc[$var]."><td width=\"300\">".$langs->trans("CurrentUserLanguage")."</td><td>".$langs->getDefaultLang()."</td></tr>\n";
|
||||
print "<tr ".$bc[$var]."><td width=\"300\">".$langs->trans("CurrentLeftMenuHandler").'</td><td colspan="2">'.$conf->left_menu."</td></tr>\n";
|
||||
$var=!$var;
|
||||
print "<tr ".$bc[$var]."><td width=\"300\">".$langs->trans("CurrentUserLanguage").'</td><td colspan="2">'.$langs->getDefaultLang()."</td></tr>\n";
|
||||
print '</table>';
|
||||
print '<br>';
|
||||
|
||||
|
||||
// Charge les modules
|
||||
$db->begin();
|
||||
|
||||
$dir = DOL_DOCUMENT_ROOT . "/includes/modules/";
|
||||
$handle=opendir($dir);
|
||||
$modules = array();
|
||||
$modules_names = array();
|
||||
$modules_files = array();
|
||||
while (($file = readdir($handle))!==false)
|
||||
{
|
||||
if (is_readable($dir.$file) && substr($file, 0, 3) == 'mod' && substr($file, strlen($file) - 10) == '.class.php')
|
||||
{
|
||||
$modName = substr($file, 0, strlen($file) - 10);
|
||||
|
||||
if ($modName)
|
||||
{
|
||||
include_once(DOL_DOCUMENT_ROOT."/includes/modules/".$file);
|
||||
$objMod = new $modName($db);
|
||||
|
||||
$modules[$objMod->numero]=$objMod;
|
||||
$modules_names[$objMod->numero]=$objMod->name;
|
||||
$modules_files[$objMod->numero]=$file;
|
||||
$picto[$objMod->numero]=(isset($objMod->picto) && $objMod->picto)?$objMod->picto:'generic';
|
||||
}
|
||||
}
|
||||
}
|
||||
print '<table class="noborder" width="100%">';
|
||||
print '<tr class="liste_titre">';
|
||||
print '<td>'.$langs->trans("Modules").'</td>';
|
||||
print '<td>'.$langs->trans("Version").'</td>';
|
||||
print '<td align="center">'.$langs->trans("Id Module").'</td>';
|
||||
print '<td>'.$langs->trans("Id Permissions").'</td>';
|
||||
print '</tr>';
|
||||
$var=false;
|
||||
$sortorder=$modules_names;
|
||||
ksort($sortorder);
|
||||
$rights_ids = array();
|
||||
foreach($sortorder as $numero=>$name)
|
||||
{
|
||||
$idperms="";
|
||||
$var=!$var;
|
||||
// Module
|
||||
print "<tr $bc[$var]><td width=\"300\" nowrap=\"nowrap\">";
|
||||
$alt=$name.' - '.$modules_files[$numero];
|
||||
print img_object($alt,$picto[$numero]).' '.$modules[$numero]->getName();
|
||||
print "</td>";
|
||||
// Version
|
||||
print '<td>'.$modules[$numero]->getVersion().'</td>';
|
||||
// Id
|
||||
print '<td align="center">'.$numero.'</td>';
|
||||
// Permissions
|
||||
if ($modules[$numero]->rights)
|
||||
{
|
||||
foreach($modules[$numero]->rights as $rights)
|
||||
{
|
||||
$idperms.=($idperms?", ":"").$rights[0];
|
||||
array_push($rights_ids, $rights[0]);
|
||||
}
|
||||
}
|
||||
print '<td>'.($idperms?$idperms:" ").'</td>';
|
||||
print "</tr>\n";
|
||||
}
|
||||
print '</table>';
|
||||
print '<br>';
|
||||
sort($rights_ids);
|
||||
foreach($rights_ids as $right_id)
|
||||
{
|
||||
if ($old == $right_id)
|
||||
print "Attention doublon sur la permission : $right_id<br>";
|
||||
$old = $right_id;
|
||||
}
|
||||
|
||||
llxFooter('$Date$ - $Revision$');
|
||||
?>
|
||||
|
|
|
|||
121
htdocs/admin/system/modules.php
Normal file
121
htdocs/admin/system/modules.php
Normal file
|
|
@ -0,0 +1,121 @@
|
|||
<?php
|
||||
/* Copyright (C) 2005-2008 Laurent Destailleur <eldy@users.sourceforge.net>
|
||||
* Copyright (C) 2007 Rodolphe Quiedeville <rodolphe@quiedeville.org>
|
||||
*
|
||||
* This program is free software; you can redistribute it and/or modify
|
||||
* it under the terms of the GNU General Public License as published by
|
||||
* the Free Software Foundation; either version 2 of the License, or
|
||||
* (at your option) any later version.
|
||||
*
|
||||
* This program is distributed in the hope that it will be useful,
|
||||
* but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
* GNU General Public License for more details.
|
||||
*
|
||||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
||||
*/
|
||||
|
||||
/**
|
||||
* \file htdocs/admin/system/dolibarr.php
|
||||
* \brief Fichier page info systemes Dolibarr
|
||||
* \version $Id$
|
||||
*/
|
||||
|
||||
require("./pre.inc.php");
|
||||
|
||||
$langs->load("admin");
|
||||
$langs->load("install");
|
||||
$langs->load("other");
|
||||
|
||||
if (!$user->admin)
|
||||
accessforbidden();
|
||||
|
||||
|
||||
/*
|
||||
* View
|
||||
*/
|
||||
|
||||
llxHeader();
|
||||
|
||||
print_fiche_titre($langs->trans("AvailableModules"),'','setup');
|
||||
|
||||
print "<br>\n";
|
||||
print $langs->trans("ToActivateModule").'<br>';
|
||||
print "<br>\n";
|
||||
|
||||
// Charge les modules
|
||||
$db->begin();
|
||||
|
||||
$dir = DOL_DOCUMENT_ROOT . "/includes/modules/";
|
||||
$handle=opendir($dir);
|
||||
$modules = array();
|
||||
$modules_names = array();
|
||||
$modules_files = array();
|
||||
while (($file = readdir($handle))!==false)
|
||||
{
|
||||
if (is_readable($dir.$file) && substr($file, 0, 3) == 'mod' && substr($file, strlen($file) - 10) == '.class.php')
|
||||
{
|
||||
$modName = substr($file, 0, strlen($file) - 10);
|
||||
|
||||
if ($modName)
|
||||
{
|
||||
include_once(DOL_DOCUMENT_ROOT."/includes/modules/".$file);
|
||||
$objMod = new $modName($db);
|
||||
|
||||
$modules[$objMod->numero]=$objMod;
|
||||
$modules_names[$objMod->numero]=$objMod->name;
|
||||
$modules_files[$objMod->numero]=$file;
|
||||
$picto[$objMod->numero]=(isset($objMod->picto) && $objMod->picto)?$objMod->picto:'generic';
|
||||
}
|
||||
}
|
||||
}
|
||||
print '<table class="noborder" width="100%">';
|
||||
print '<tr class="liste_titre">';
|
||||
print '<td>'.$langs->trans("Modules").'</td>';
|
||||
print '<td>'.$langs->trans("Version").'</td>';
|
||||
print '<td align="center">'.$langs->trans("Id Module").'</td>';
|
||||
print '<td>'.$langs->trans("Id Permissions").'</td>';
|
||||
print '</tr>';
|
||||
$var=false;
|
||||
$sortorder=$modules_names;
|
||||
ksort($sortorder);
|
||||
$rights_ids = array();
|
||||
foreach($sortorder as $numero=>$name)
|
||||
{
|
||||
$idperms="";
|
||||
$var=!$var;
|
||||
// Module
|
||||
print "<tr $bc[$var]><td width=\"300\" nowrap=\"nowrap\">";
|
||||
$alt=$name.' - '.$modules_files[$numero];
|
||||
print img_object($alt,$picto[$numero]).' '.$modules[$numero]->getName();
|
||||
print "</td>";
|
||||
// Version
|
||||
print '<td>'.$modules[$numero]->getVersion().'</td>';
|
||||
// Id
|
||||
print '<td align="center">'.$numero.'</td>';
|
||||
// Permissions
|
||||
if ($modules[$numero]->rights)
|
||||
{
|
||||
foreach($modules[$numero]->rights as $rights)
|
||||
{
|
||||
$idperms.=($idperms?", ":"").$rights[0];
|
||||
array_push($rights_ids, $rights[0]);
|
||||
}
|
||||
}
|
||||
print '<td>'.($idperms?$idperms:" ").'</td>';
|
||||
print "</tr>\n";
|
||||
}
|
||||
print '</table>';
|
||||
print '<br>';
|
||||
sort($rights_ids);
|
||||
foreach($rights_ids as $right_id)
|
||||
{
|
||||
if ($old == $right_id)
|
||||
print "Attention doublon sur la permission : $right_id<br>";
|
||||
$old = $right_id;
|
||||
}
|
||||
|
||||
llxFooter('$Date$ - $Revision$');
|
||||
?>
|
||||
|
|
@ -17,15 +17,13 @@
|
|||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
||||
*
|
||||
* $Id$
|
||||
*/
|
||||
|
||||
/**
|
||||
\file htdocs/admin/system/pre.inc.php
|
||||
\brief Fichier gestionnaire menu page infos système
|
||||
\version $Revision$
|
||||
*/
|
||||
* \file htdocs/admin/system/pre.inc.php
|
||||
* \brief Fichier gestionnaire menu page infos système
|
||||
* \version $Id$
|
||||
*/
|
||||
|
||||
require("../../main.inc.php");
|
||||
|
||||
|
|
@ -45,7 +43,8 @@ function llxHeader($head = "", $urlp = "")
|
|||
// Dolibarr
|
||||
$menu->add(DOL_URL_ROOT."/admin/system/dolibarr.php", "Dolibarr");
|
||||
$menu->add_submenu(DOL_URL_ROOT."/admin/system/constall.php", $langs->trans("AllParameters"));
|
||||
$menu->add_submenu(DOL_URL_ROOT."/admin/triggers.php", $langs->trans("Triggers"));
|
||||
$menu->add_submenu(DOL_URL_ROOT."/admin/system/modules.php", $langs->trans("Modules"));
|
||||
$menu->add_submenu(DOL_URL_ROOT."/admin/triggers.php", $langs->trans("Triggers"));
|
||||
$menu->add_submenu(DOL_URL_ROOT."/about.php", $langs->trans("About"));
|
||||
|
||||
// OS
|
||||
|
|
@ -56,9 +55,6 @@ function llxHeader($head = "", $urlp = "")
|
|||
|
||||
// PHP
|
||||
$menu->add(DOL_URL_ROOT."/admin/system/phpinfo.php", $langs->trans("Php"));
|
||||
$menu->add_submenu(DOL_URL_ROOT."/admin/system/phpinfo.php?what=conf", $langs->trans("PhpConf"));
|
||||
$menu->add_submenu(DOL_URL_ROOT."/admin/system/phpinfo.php?what=env", $langs->trans("PhpEnv"));
|
||||
$menu->add_submenu(DOL_URL_ROOT."/admin/system/phpinfo.php?what=modules", $langs->trans("PhpModules"));
|
||||
|
||||
// Database
|
||||
$menu->add(DOL_URL_ROOT."/admin/system/database.php", $langs->trans("Database"));
|
||||
|
|
|
|||
|
|
@ -14,15 +14,13 @@
|
|||
* You should have received a copy of the GNU General Public License
|
||||
* along with this program; if not, write to the Free Software
|
||||
* Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
|
||||
*
|
||||
* $Id$
|
||||
*/
|
||||
|
||||
/**
|
||||
\file htdocs/admin/triggers.php
|
||||
\brief Page de configuration et activation des triggers
|
||||
\version $Revision$
|
||||
*/
|
||||
* \file htdocs/admin/triggers.php
|
||||
* \brief Page de configuration et activation des triggers
|
||||
* \version $Id$
|
||||
*/
|
||||
|
||||
require("./pre.inc.php");
|
||||
include_once(DOL_DOCUMENT_ROOT ."/interfaces.class.php");
|
||||
|
|
|
|||
|
|
@ -131,6 +131,7 @@ class MenuLeft {
|
|||
$newmenu->add(DOL_URL_ROOT."/admin/system/index.php?leftmenu=system", $langs->trans("SystemInfo"));
|
||||
if ($leftmenu=="system") $newmenu->add_submenu(DOL_URL_ROOT."/admin/system/dolibarr.php", $langs->trans("Dolibarr"),1);
|
||||
if ($leftmenu=="system") $newmenu->add_submenu(DOL_URL_ROOT."/admin/system/constall.php", $langs->trans("AllParameters"),2);
|
||||
if ($leftmenu=="system") $newmenu->add_submenu(DOL_URL_ROOT."/admin/system/modules.php", $langs->trans("Modules"),2);
|
||||
if ($leftmenu=="system") $newmenu->add_submenu(DOL_URL_ROOT."/admin/triggers.php", $langs->trans("Triggers"),2);
|
||||
if ($leftmenu=="system") $newmenu->add_submenu(DOL_URL_ROOT."/about.php", $langs->trans("About"),2);
|
||||
if ($leftmenu=="system") $newmenu->add_submenu(DOL_URL_ROOT."/admin/system/os.php", $langs->trans("OS"));
|
||||
|
|
|
|||
|
|
@ -133,6 +133,7 @@ class MenuLeft {
|
|||
$newmenu->add(DOL_URL_ROOT."/admin/system/index.php?leftmenu=system", $langs->trans("SystemInfo"));
|
||||
if ($leftmenu=="system") $newmenu->add_submenu(DOL_URL_ROOT."/admin/system/dolibarr.php", $langs->trans("Dolibarr"),1);
|
||||
if ($leftmenu=="system") $newmenu->add_submenu(DOL_URL_ROOT."/admin/system/constall.php", $langs->trans("AllParameters"),2);
|
||||
if ($leftmenu=="system") $newmenu->add_submenu(DOL_URL_ROOT."/admin/system/modules.php", $langs->trans("Modules"),2);
|
||||
if ($leftmenu=="system") $newmenu->add_submenu(DOL_URL_ROOT."/admin/triggers.php", $langs->trans("Triggers"),2);
|
||||
if ($leftmenu=="system") $newmenu->add_submenu(DOL_URL_ROOT."/about.php", $langs->trans("About"),2);
|
||||
if ($leftmenu=="system") $newmenu->add_submenu(DOL_URL_ROOT."/admin/system/os.php", $langs->trans("OS"));
|
||||
|
|
|
|||
|
|
@ -581,7 +581,11 @@ SystemInfoDesc=System information is miscellanous technical information you get
|
|||
SystemAreaForAdminOnly=This area is available for administrator users only. None of the Dolibarr permissions can reduce this limit.
|
||||
CompanyFundationDesc=Edit on this page all known information of the company or fundation you need to manage
|
||||
DisplayDesc=You can choose each parameter related to the Dolibarr look and feel here
|
||||
TriggersAvailable=Triggers available
|
||||
AvailableModules=Available modules
|
||||
ToActivateModule=To activate modules, go on setup Area.
|
||||
SessionTimeOut=Time out for session
|
||||
SessionExplanation=This number guarantee that session will never expire before this delay. But PHP sessoin management does not guaranty that session always expire after this delay: This occurs if a system to clean cache session is running.<br>Note: with no particular system, internal PHP process will clean session every about <b>%s/%s</b> access but only during access made by other sessions.
|
||||
TriggersAvailable=Available triggers
|
||||
TriggersDesc=Triggers are files that will modify the behaviour of Dolibarr workflow once copied into the directory <b>htdocs/includes/triggers</b>. They realised new actions, activated on Dolibarr events (new company creation, invoice validation, ...).
|
||||
TriggerDisabledByName=Triggers in this file are disabled by the <b>-NORUN</b> suffix in their name.
|
||||
TriggerDisabledAsModuleDisabled=Triggers in this file are disabled as module <b>%s</b> is disabled.
|
||||
|
|
|
|||
|
|
@ -580,6 +580,10 @@ SystemInfoDesc=Les informations syst
|
|||
SystemAreaForAdminOnly=Cet espace n'est accessible qu'aux utilisateurs de type administrateurs. Aucune permission Dolibarr ne permet d'étendre le cercle des utilisateurs autorisés à cet espace.
|
||||
CompanyFundationDesc=Éditer sur cette page toutes les informations connues sur la société ou association que vous devez gérer
|
||||
DisplayDesc=Vous pouvez choisir ici tous les paramètres liés à l'apparence de Dolibarr
|
||||
AvailableModules=Modules disponibles
|
||||
ToActivateModule=Pour activer des modules, aller dans l'espace Configuration.
|
||||
SessionTimeOut=Time out des sessions
|
||||
SessionExplanation=Ce nombre garantie que la session n'expire pas avant ce délai. Mais la gestion de session PHP ne garantie pas que la session expire après ce délai: Ce sera le cas si un systeme de nettoyage des caches sessions est en place.<br>Note: Sans mécanisme special, le mécanisme interne à PHP nettoie la session tous les <b>%s/%s</b> accès environ mais uniquement lors d'accès fait par d'autres sessions.
|
||||
TriggersAvailable=Triggers disponibles
|
||||
TriggersDesc=Les triggers sont des fichiers qui, une fois déposés dans le répertoire <b>htdocs/includes/triggers</b>, modifient le comportement du workflow de Dolibarr. Ils réalisent des actions supplémentaires, déclenchées par les événements Dolibarr (création société, validation facture, clôture contrat...).
|
||||
TriggerDisabledByName=Triggers de ce fichier désactivés par le suffix <b>-NORUN</b> dans le nom du fichier.
|
||||
|
|
|
|||
|
|
@ -37,6 +37,7 @@ require_once ARTICHOW."/AntiSpam.class.php";
|
|||
|
||||
// Init session
|
||||
$sessionname="DOLSESSID_".$dolibarr_main_db_name;
|
||||
if (! empty($conf->global->MAIN_SESSION_TIMEOUT)) ini_set('session.gc_maxlifetime',$conf->global->MAIN_SESSION_TIMEOUT);
|
||||
session_name($sessionname);
|
||||
session_start();
|
||||
dolibarr_syslog("Session name=".$sessionname." Session id()=".session_id().", _SESSION['dol_login']=".$_SESSION["dol_login"]);
|
||||
|
|
|
|||
|
|
@ -139,10 +139,10 @@ if (! defined('NOREQUIREAJAX') && $conf->use_javascript_ajax) require_once(DOL_D
|
|||
|
||||
// Init session
|
||||
$sessionname="DOLSESSID_".$dolibarr_main_db_name;
|
||||
//ini_set('session.gc_maxlifetime',10);
|
||||
if (! empty($conf->global->MAIN_SESSION_TIMEOUT)) ini_set('session.gc_maxlifetime',$conf->global->MAIN_SESSION_TIMEOUT);
|
||||
session_name($sessionname);
|
||||
session_start();
|
||||
dolibarr_syslog("Session name=".$sessionname." Session id()=".session_id().", _SESSION['dol_login']=".$_SESSION["dol_login"]);
|
||||
dolibarr_syslog("Start session name=".$sessionname." Session id()=".session_id().", _SESSION['dol_login']=".$_SESSION["dol_login"]);
|
||||
|
||||
/*
|
||||
* Phase identification
|
||||
|
|
|
|||
|
|
@ -43,9 +43,14 @@ if ($conf->phenix->enabled && $conf->phenix->cookie)
|
|||
dolibarr_syslog("End session in DOLSESSID_".$dolibarr_main_db_name);
|
||||
|
||||
session_destroy();
|
||||
|
||||
// Init session
|
||||
$sessionname="DOLSESSID_".$dolibarr_main_db_name;
|
||||
if (! empty($conf->global->MAIN_SESSION_TIMEOUT)) ini_set('session.gc_maxlifetime',$conf->global->MAIN_SESSION_TIMEOUT);
|
||||
session_name($sessionname);
|
||||
session_start();
|
||||
dolibarr_syslog("Start session name=".$sessionname." Session id()=".session_id().", _SESSION['dol_login']=".$_SESSION["dol_login"]);
|
||||
|
||||
session_unregister("dol_login");
|
||||
|
||||
header("Location: ".DOL_URL_ROOT."/index.php");
|
||||
|
|
|
|||
|
|
@ -151,7 +151,7 @@ if ($_GET["action"] == 'edit')
|
|||
$var=!$var;
|
||||
print '<tr '.$bc[$var].'><td>'.$langs->trans("Language").'</td>';
|
||||
print '<td>'.($conf->global->MAIN_LANG_DEFAULT=='auto'?$langs->trans("AutoDetectLang"):$conf->global->MAIN_LANG_DEFAULT).'</td>';
|
||||
print '<td align="left" nowrap="nowrap" width="20%"><input name="check_MAIN_LANG_DEFAULT" type="checkbox" '.($fuser->conf->MAIN_LANG_DEFAULT?" checked":"");
|
||||
print '<td align="left" nowrap="nowrap" width="20%"><input '.$bc[$var].' name="check_MAIN_LANG_DEFAULT" type="checkbox" '.($fuser->conf->MAIN_LANG_DEFAULT?" checked":"");
|
||||
print ! empty($conf->global->MAIN_DEMO)?' disabled="true"':''; // Disabled for demo
|
||||
print '> '.$langs->trans("UsePersonalValue").'</td>';
|
||||
print '<td>';
|
||||
|
|
@ -163,7 +163,7 @@ if ($_GET["action"] == 'edit')
|
|||
$var=!$var;
|
||||
print '<tr '.$bc[$var].'><td>'.$langs->trans("MaxSizeList").'</td>';
|
||||
print '<td>'.$conf->global->MAIN_SIZE_LISTE_LIMIT.'</td>';
|
||||
print '<td align="left" nowrap="nowrap" width="20%"><input name="check_SIZE_LISTE_LIMIT" type="checkbox" '.($fuser->conf->MAIN_SIZE_LISTE_LIMIT?" checked":"");
|
||||
print '<td align="left" nowrap="nowrap" width="20%"><input '.$bc[$var].' name="check_SIZE_LISTE_LIMIT" type="checkbox" '.($fuser->conf->MAIN_SIZE_LISTE_LIMIT?" checked":"");
|
||||
print ! empty($conf->global->MAIN_DEMO)?' disabled="true"':''; // Disabled for demo
|
||||
print '> '.$langs->trans("UsePersonalValue").'</td>';
|
||||
print '<td><input class="flat" name="main_size_liste_limit" size="4" value="' . $fuser->conf->SIZE_LISTE_LIMIT . '"></td></tr>';
|
||||
|
|
@ -194,13 +194,13 @@ else
|
|||
$var=!$var;
|
||||
print '<tr '.$bc[$var].'><td>'.$langs->trans("Language").'</td>';
|
||||
print '<td>'.($conf->global->MAIN_LANG_DEFAULT=='auto'?$langs->trans("AutoDetectLang"):$conf->global->MAIN_LANG_DEFAULT).'</td>';
|
||||
print '<td align="left" nowrap="nowrap" width="20%"><input type="checkbox" disabled '.($fuser->conf->MAIN_LANG_DEFAULT?" checked":"").'> '.$langs->trans("UsePersonalValue").'</td>';
|
||||
print '<td align="left" nowrap="nowrap" width="20%"><input '.$bc[$var].' type="checkbox" disabled '.($fuser->conf->MAIN_LANG_DEFAULT?" checked":"").'> '.$langs->trans("UsePersonalValue").'</td>';
|
||||
print '<td>'.($fuser->conf->MAIN_LANG_DEFAULT=='auto'?$langs->trans("AutoDetectLang"):$fuser->conf->MAIN_LANG_DEFAULT).'</td></tr>';
|
||||
|
||||
$var=!$var;
|
||||
print '<tr '.$bc[$var].'><td>'.$langs->trans("MaxSizeList").'</td>';
|
||||
print '<td>'.$conf->global->MAIN_SIZE_LISTE_LIMIT.'</td>';
|
||||
print '<td align="left" nowrap="nowrap" width="20%"><input type="checkbox" disabled '.($fuser->conf->MAIN_SIZE_LISTE_LIMIT?" checked":"").'> '.$langs->trans("UsePersonalValue").'</td>';
|
||||
print '<td align="left" nowrap="nowrap" width="20%"><input '.$bc[$var].' type="checkbox" disabled '.($fuser->conf->MAIN_SIZE_LISTE_LIMIT?" checked":"").'> '.$langs->trans("UsePersonalValue").'</td>';
|
||||
print '<td>' . $fuser->conf->MAIN_SIZE_LISTE_LIMIT . '</td></tr>';
|
||||
|
||||
print '</table><br>';
|
||||
|
|
@ -250,7 +250,7 @@ function show_theme($fuser,$edit=0)
|
|||
|
||||
print '<tr '.$bc[$var].'><td>'.$langs->trans("DefaultSkin").'</td>';
|
||||
print '<td>'.$conf->global->MAIN_THEME.'</td>';
|
||||
print '<td '.$bc[$var].' align="left" nowrap="nowrap" width="20%"><input name="check_MAIN_THEME"'.($edit?'':' disabled').' type="checkbox" '.($fuser->conf->MAIN_THEME?" checked":"").'> '.$langs->trans("UsePersonalValue").'</td>';
|
||||
print '<td '.$bc[$var].' align="left" nowrap="nowrap" width="20%"><input '.$bc[$var].' name="check_MAIN_THEME"'.($edit?'':' disabled').' type="checkbox" '.($fuser->conf->MAIN_THEME?" checked":"").'> '.$langs->trans("UsePersonalValue").'</td>';
|
||||
print '<td '.$bc[$var].'> </td></tr>';
|
||||
|
||||
$var=!$var;
|
||||
|
|
|
|||
|
|
@ -32,9 +32,10 @@ require_once(DOL_DOCUMENT_ROOT."/lib/usergroups.lib.php");
|
|||
|
||||
// Init session
|
||||
$sessionname="DOLSESSID_".$dolibarr_main_db_name;
|
||||
if (! empty($conf->global->MAIN_SESSION_TIMEOUT)) ini_set('session.gc_maxlifetime',$conf->global->MAIN_SESSION_TIMEOUT);
|
||||
session_name($sessionname);
|
||||
session_start();
|
||||
dolibarr_syslog("Session name=".$sessionname." Session id()=".session_id().", _SESSION['dol_login']=".$_SESSION["dol_login"]);
|
||||
dolibarr_syslog("Start session name=".$sessionname." Session id()=".session_id().", _SESSION['dol_login']=".$_SESSION["dol_login"]);
|
||||
|
||||
$user->getrights('user');
|
||||
|
||||
|
|
|
|||
Loading…
Reference in New Issue
Block a user