diff --git a/include/ajax/ajax_admin.php b/include/ajax/ajax_admin.php
index 49df5faef..5715b3c29 100644
--- a/include/ajax/ajax_admin.php
+++ b/include/ajax/ajax_admin.php
@@ -27,6 +27,7 @@ if (!defined('ALLOWED'))
* admin-noalyss.php
* @see admin-noalyss.php ajax_misc.php admin.js
*/
+global $g_user;
if ($g_user->Admin()==0)
{
die();
@@ -239,8 +240,16 @@ if (in_array($op, array('modele_drop', 'modele_modify', 'folder_modify', 'folder
$max_email_input->value=$dos->get_parameter('max_email');
$max_email_input->prec=0;
echo $max_email_input->input();
- echo '
';
+ echo '
';
+ echo "- ";
echo HtmlInput::submit('upd', _('Modifie'));
+ echo "
";
+ echo "- ";
+ echo HtmlInput::button_close("folder_admin_div");
+ echo "
";
+ echo '
';
+
+
echo '';
$content=ob_get_clean();
$status='OK';
@@ -263,10 +272,16 @@ if (in_array($op, array('modele_drop', 'modele_modify', 'folder_modify', 'folder
echo _("Tapez le code de confirmation");
echo confirm_with_string("fld_drop",5);
echo '';
- echo '';
+ echo '
';
+ echo "- ";
echo HtmlInput::submit('remove', _('Effacer'));
- echo '';
+ echo "
";
+ echo "- ";
+ echo HtmlInput::button_close("folder_admin_div");
+ echo "
";
+ echo '
';
echo '';
+
$content=ob_get_clean();
$status='OK';
}
@@ -288,9 +303,15 @@ if (in_array($op, array('modele_drop', 'modele_modify', 'folder_modify', 'folder
echo _('Cochez la case si vous êtes sûr de vouloir effacer ce modèle');
echo $confirm->input();
echo '';
- echo '';
+ echo '
';
+ echo "- ";
echo HtmlInput::submit('remove', _('Effacer'));
- echo '';
+ echo "
";
+ echo "- ";
+ echo HtmlInput::button_close("folder_admin_div");
+ echo "
";
+ echo '
';
+
echo '';
$content=ob_get_clean();
$status='OK';
@@ -317,8 +338,17 @@ if (in_array($op, array('modele_drop', 'modele_modify', 'folder_modify', 'folder
echo $wDesc->input('desc', $desc);
echo HtmlInput::hidden('m', $dossier);
echo HtmlInput::hidden('action', 'modele_mgt');
- echo '
';
- echo HtmlInput::submit('upd', _('Modifie'));
+
+ echo '';
+ echo "- ";
+ echo HtmlInput::submit('upd', _('Modifie'));
+ echo "
";
+ echo "- ";
+ echo HtmlInput::button_close("folder_admin_div");
+ echo "
";
+ echo '
';
+
+
echo '';
$content=ob_get_clean();
$status='OK';
diff --git a/include/lib/sort_table.class.php b/include/lib/sort_table.class.php
index 15a7ebfbc..f14e6a430 100644
--- a/include/lib/sort_table.class.php
+++ b/include/lib/sort_table.class.php
@@ -25,6 +25,8 @@
*/
class Sort_Table
{
+ private $nb;
+ private $array;
function __construct()
{
@@ -35,12 +37,12 @@ class Sort_Table
/**
*@brief add row of a header in the internal array ($this->array)
* , it uses the $_GET['ord'] parameter,
- * @param type $p_header label of the header
- * @param type $p_url base url
- * @param type $p_sql_asc sql if ascending
- * @param type $p_sql_desc sql if descending
- * @param type $p_get_asc the value in $_GET if ascending is choosen
- * @param type $p_get_desc the value in $_GET if descending is choosen
+ * @param string $p_header label of the header
+ * @param string $p_url base url
+ * @param string $p_sql_asc sql if ascending
+ * @param string $p_sql_desc sql if descending
+ * @param string $p_get_asc the value in $_GET if ascending is choosen
+ * @param string $p_get_desc the value in $_GET if descending is choosen
*/
function add($p_header, $p_url, $p_sql_asc, $p_sql_desc, $p_get_asc, $p_get_desc)
{
@@ -51,8 +53,8 @@ class Sort_Table
'sql_desc' => $p_sql_desc,
'parm_asc' => $p_get_asc,
'parm_desc' => $p_get_desc,
- 'car_asc' => '▲',
- 'car_desc' => '▼'
+ 'car_asc' => '▲',
+ 'car_desc' => '▼'
);
$ind = $this->nb;
$this->array[$ind] = $array;
@@ -61,7 +63,7 @@ class Sort_Table
/**
* Returns the header (the value into th tags) with the symbol ascending and
* descending
- * @param $p_ind the element (from 0 to nb)
+ * @param int $p_ind the element (from 0 to nb)
* @return string
*/
function get_header($p_ind)
@@ -84,19 +86,19 @@ class Sort_Table
function get_sql_order($p_get)
{
- for ($i = 0; $i < $this->nb; $i++)
- {
- if ($p_get == $this->array[$i]['parm_asc'])
- {
- $this->array[$i]['car_asc'] = '▲';
- return $this->array[$i]['sql_asc'];
- }
- if ($p_get == $this->array[$i]['parm_desc'])
- {
- $this->array[$i]['car_desc'] = '▼';
- return $this->array[$i]['sql_desc'];
- }
- }
+ for ($i = 0; $i < $this->nb; $i++)
+ {
+ if ($p_get == $this->array[$i]['parm_asc'])
+ {
+ $this->array[$i]['car_asc'] = '▲';
+ return $this->array[$i]['sql_asc'];
+ }
+ if ($p_get == $this->array[$i]['parm_desc'])
+ {
+ $this->array[$i]['car_desc'] = '▼';
+ return $this->array[$i]['sql_desc'];
+ }
+ }
}
}