diff --git a/htdocs/admin/tools/dolibarr_import.php b/htdocs/admin/tools/dolibarr_import.php
index ad0e08faf7c..6ff920e3b2c 100644
--- a/htdocs/admin/tools/dolibarr_import.php
+++ b/htdocs/admin/tools/dolibarr_import.php
@@ -110,7 +110,7 @@ print '
';
$paramclear=$param;
if (! empty($dolibarr_main_db_pass))
{
- $paramcrypted.=" -p".eregi_replace('.','*',$dolibarr_main_db_pass);
+ $paramcrypted.=" -p".preg_replace('/./i','*',$dolibarr_main_db_pass);
$paramclear.=" -p".$dolibarr_main_db_pass;
}
diff --git a/htdocs/admin/tools/export.php b/htdocs/admin/tools/export.php
index 50ae88c03db..51b38fd0800 100644
--- a/htdocs/admin/tools/export.php
+++ b/htdocs/admin/tools/export.php
@@ -125,7 +125,7 @@ if ($what == 'mysql')
$paramclear=$param;
if (! empty($dolibarr_main_db_pass))
{
- $paramcrypted.=" -p".eregi_replace('.','*',$dolibarr_main_db_pass);
+ $paramcrypted.=" -p".preg_replace('/./i','*',$dolibarr_main_db_pass);
$paramclear.=" -p".$dolibarr_main_db_pass;
}
diff --git a/htdocs/admin/tools/purge.php b/htdocs/admin/tools/purge.php
index 5fd6eac19b1..d1b92d14439 100644
--- a/htdocs/admin/tools/purge.php
+++ b/htdocs/admin/tools/purge.php
@@ -38,7 +38,7 @@ $filelog='';
if ($conf->syslog->enabled)
{
$filelog=SYSLOG_FILE;
- $filelog=eregi_replace('DOL_DATA_ROOT',DOL_DATA_ROOT,$filelog);
+ $filelog=preg_replace('/DOL_DATA_ROOT/i',DOL_DATA_ROOT,$filelog);
}
diff --git a/htdocs/admin/tools/update.php b/htdocs/admin/tools/update.php
index 9f295e76ac6..2c9b72db89d 100644
--- a/htdocs/admin/tools/update.php
+++ b/htdocs/admin/tools/update.php
@@ -38,8 +38,8 @@ if ($_GET["msg"]) $message='