From fc95db277e33e2747f590532962e2b53a56684c4 Mon Sep 17 00:00:00 2001 From: sparkyx Date: Sat, 27 Jan 2024 15:48:05 +0100 Subject: [PATCH] remove access global var Cosmetic disconnect --- include/customer.inc.php | 2 +- include/lib/ac_common.php | 4 ++-- include/lib/html_input.class.php | 3 ++- 3 files changed, 5 insertions(+), 4 deletions(-) diff --git a/include/customer.inc.php b/include/customer.inc.php index afc61c3c6..77501a14c 100644 --- a/include/customer.inc.php +++ b/include/customer.inc.php @@ -26,7 +26,7 @@ if ( ! defined ('ALLOWED') ) die('Appel direct ne sont pas permis'); $http=new HttpInput(); -$low_action = (isset($_REQUEST['sb'])) ? $_REQUEST['sb'] : "list"; +$low_action = $http->request("sb","string","list"); /** \file * \brief Called from the module "Gestion" to manage the customer */ diff --git a/include/lib/ac_common.php b/include/lib/ac_common.php index 5aa23874e..88e95ed7f 100644 --- a/include/lib/ac_common.php +++ b/include/lib/ac_common.php @@ -909,7 +909,7 @@ function ajax_disconnected($p_div) echo HtmlInput::title_box(_("Déconnecté"), $p_div); echo h2(_('Données non disponibles'), 'class="error" '); echo h2(_('Veuillez vous reconnecter soit dans une autre fenêtre soit ' - . ' en cliquant sur le lien'), 'class="error"'); + . ' en cliquant sur le bouton'), 'class="error"'); // Reload button $reload=new IButton("reload"); $reload->value=_("Se connecter"); @@ -918,7 +918,7 @@ function ajax_disconnected($p_div) // Link to log in another tab echo '

'; echo $reload->input(); - echo HtmlInput::button_close($p_div); + echo HtmlInput::button_close($p_div,'button'); echo '

'; diff --git a/include/lib/html_input.class.php b/include/lib/html_input.class.php index 4250f9394..de151e6d6 100755 --- a/include/lib/html_input.class.php +++ b/include/lib/html_input.class.php @@ -444,10 +444,11 @@ class HtmlInput * @see add_div modify_operation * @param $div_name is the name of the div to remove */ - static function button_close($div_name) + static function button_close($div_name,$class='smallbutton') { $a=new IButton('Fermer'); $a->label=_("Fermer"); + $a->class=$class; $a->javascript="removeDiv('".$div_name."')"; $html=$a->input();