mirror of
https://github.com/Dolibarr/dolibarr.git
synced 2026-02-13 11:15:21 +01:00
Fix: functions "ereg", "ereg_replace", "eregi", "eregi_replace" is deprecated since php 5.3.0
This commit is contained in:
@@ -32,7 +32,7 @@ $langs->load("admin");
|
||||
if (!$user->admin)
|
||||
accessforbidden();
|
||||
|
||||
// D<>finition des positions possibles pour les boites
|
||||
// D<>finition des positions possibles pour les boites
|
||||
$pos_array = array(0); // Positions possibles pour une boite (0,1,2,...)
|
||||
$pos_name = array(0=>$langs->trans("Home")); // Nom des positions 0=Homepage, 1=...
|
||||
$boxes = array();
|
||||
@@ -170,7 +170,7 @@ if ($resql)
|
||||
array_push($actives,$obj->box_id);
|
||||
|
||||
if ($obj->box_order == '' || $obj->box_order == '0' || $decalage) $decalage++;
|
||||
// On renum<75>rote l'ordre des boites si l'une d'elle est <20> ''
|
||||
// On renum<75>rote l'ordre des boites si l'une d'elle est <20> ''
|
||||
// This occurs just after an insert.
|
||||
if ($decalage)
|
||||
{
|
||||
@@ -261,7 +261,7 @@ if ($resql)
|
||||
{
|
||||
$obj = $db->fetch_object($resql);
|
||||
|
||||
$module=eregi_replace('.php$','',$obj->file);
|
||||
$module=preg_replace('/.php$/i','',$obj->file);
|
||||
include_once(DOL_DOCUMENT_ROOT."/includes/boxes/".$module.".php");
|
||||
|
||||
$box=new $module($db,$obj->note);
|
||||
@@ -269,7 +269,7 @@ if ($resql)
|
||||
// if (in_array($obj->rowid, $actives) && $box->box_multiple <> 1)
|
||||
if (in_array($obj->rowid, $actives))
|
||||
{
|
||||
// La boite est d<EFBFBD>j<EFBFBD> activ<EFBFBD>e
|
||||
// La boite est deja activee
|
||||
}
|
||||
else
|
||||
{
|
||||
@@ -277,7 +277,7 @@ if ($resql)
|
||||
|
||||
print '<form action="'.$_SERVER["PHP_SELF"].'" method="POST">';
|
||||
print '<input type="hidden" name="token" value="'.$_SESSION['newtoken'].'">';
|
||||
$logo=eregi_replace("^object_","",$box->boximg);
|
||||
$logo=preg_replace("/^object_/i","",$box->boximg);
|
||||
print '<tr '.$bc[$var].'>';
|
||||
print '<td>'.img_object("",$logo).' '.$box->boxlabel.'</td>';
|
||||
print '<td>' . ($obj->note?$obj->note:' ') . '</td>';
|
||||
@@ -303,7 +303,7 @@ if ($resql)
|
||||
print '</table>';
|
||||
|
||||
/*
|
||||
* Boites activ<69>es
|
||||
* Boites activ<69>es
|
||||
*
|
||||
*/
|
||||
|
||||
@@ -346,11 +346,11 @@ if ($resql)
|
||||
$var = ! $var;
|
||||
$objnext = $db->fetch_object($resql);
|
||||
|
||||
$module=eregi_replace('.php$','',$obj->file);
|
||||
$module=preg_replace('/.php$/i','',$obj->file);
|
||||
include_once(DOL_DOCUMENT_ROOT."/includes/boxes/".$module.".php");
|
||||
$box=new $module($db,$obj->note);
|
||||
|
||||
$logo=eregi_replace("^object_","",$box->boximg);
|
||||
$logo=preg_replace("/^object_/i","",$box->boximg);
|
||||
print '<tr '.$bc[$var].'>';
|
||||
print '<td>'.img_object("",$logo).' '.$box->boxlabel.'</td>';
|
||||
print '<td>' . ($obj->note?$obj->note:' ') . '</td>';
|
||||
|
||||
Reference in New Issue
Block a user