diff --git a/html/install.php b/html/install.php index 25dd70e3f..79615bb15 100644 --- a/html/install.php +++ b/html/install.php @@ -216,7 +216,7 @@ $locale=HtmlInput::default_value_request("clocale", "1"); $ctmp=HtmlInput::default_value_request("ctmp", "/tmp"); $cpath=HtmlInput::default_value_request("cpath", "/usr/bin"); $db_name=HtmlInput::default_value_request("cdbname", ""); -$cadmin=HtmlInput::default_value_request("cadmin", "phpcompta"); +$cadmin=HtmlInput::default_value_request("cadmin", "admin"); $cadmin=strtolower($cadmin); //------------------------------------------------------------------------- // warn only if we can not write in include diff --git a/include/constant.php b/include/constant.php index 2d9868892..52eb76de4 100644 --- a/include/constant.php +++ b/include/constant.php @@ -47,6 +47,7 @@ if ( !defined("NOALYSS_TEMPLATE")) define ("NOALYSS_TEMPLATE",$g_template_dir); // with convert if ( !defined("FIX_BROKEN_PDF")) define ("FIX_BROKEN_PDF",'NO'); +// version < 6.9.1.4 , the default administrator was Noalyss if ( !defined('NOALYSS_ADMINISTRATOR')) { define ('NOALYSS_ADMINISTRATOR','phpcompta'); } diff --git a/include/param_sec.inc.php b/include/param_sec.inc.php index 77cab8eaa..804d75244 100644 --- a/include/param_sec.inc.php +++ b/include/param_sec.inc.php @@ -68,8 +68,8 @@ if ( ! isset($_REQUEST['action'])) use_login, use_admin from ac_users left join jnt_use_dos using (use_id) - where use_login != 'phpcompta' and use_active=1 - and (dos_id=$1 or (dos_id is null and use_admin=1))" . $ord_sql, array($gDossier)); + where use_login != $2 and use_active=1 + and (dos_id=$1 or (dos_id is null and use_admin=1))" . $ord_sql, array($gDossier,NOALYSS_ADMINISTRATOR)); $MaxUser = Database::num_row($user_sql);