Standardize and update code
This commit is contained in:
parent
961505d510
commit
18f4755a90
@ -727,8 +727,8 @@ class FormTicket
|
||||
{
|
||||
global $conf, $langs, $user, $mysoc;
|
||||
|
||||
$langs->load("other");
|
||||
$langs->load("mails");
|
||||
// Load translation files required by the page
|
||||
$langs->loadLangs(array('other', 'mails'));
|
||||
|
||||
$addfileaction = 'addfile';
|
||||
|
||||
|
||||
@ -1141,8 +1141,8 @@ function dol_delete_file($file,$disableglob=0,$nophperrors=0,$nohook=0,$object=n
|
||||
global $db, $conf, $user, $langs;
|
||||
global $hookmanager;
|
||||
|
||||
$langs->load("other");
|
||||
$langs->load("errors");
|
||||
// Load translation files required by the page
|
||||
$langs->loadLangs(array('other', 'errors'));
|
||||
|
||||
dol_syslog("dol_delete_file file=".$file." disableglob=".$disableglob." nophperrors=".$nophperrors." nohook=".$nohook);
|
||||
|
||||
|
||||
@ -3865,8 +3865,8 @@ function dol_print_error($db='',$error='',$errors=null)
|
||||
$langs = new Translate('', $conf);
|
||||
$langs->load("main");
|
||||
}
|
||||
$langs->load("main");
|
||||
$langs->load("errors");
|
||||
// Load translation files required by the page
|
||||
$langs->loadLangs(array('main', 'errors'));
|
||||
|
||||
if ($_SERVER['DOCUMENT_ROOT']) // Mode web
|
||||
{
|
||||
|
||||
@ -105,9 +105,9 @@ function checkLoginPassEntity($usertotest,$passwordtotest,$entitytotest,$authmod
|
||||
{
|
||||
dol_syslog("Authentification ko - failed to load file '".$authfile."'", LOG_ERR);
|
||||
sleep(1);
|
||||
$langs->load('main');
|
||||
$langs->load('other');
|
||||
$langs->load('errors');
|
||||
// Load translation files required by the page
|
||||
$langs->loadLangs(array('other', 'main', 'errors'));
|
||||
|
||||
$_SESSION["dol_loginmesg"]=$langs->trans("ErrorFailedToLoadLoginFileForMode", $mode);
|
||||
}
|
||||
}
|
||||
|
||||
Loading…
Reference in New Issue
Block a user