diff --git a/htdocs/core/class/utils.class.php b/htdocs/core/class/utils.class.php
index 6f01a4c1406..3f1afa003a3 100644
--- a/htdocs/core/class/utils.class.php
+++ b/htdocs/core/class/utils.class.php
@@ -146,9 +146,10 @@ class Utils
* @param string $type 'mysql', 'postgresql', ...
* @param int $usedefault 1=Use default backup profile (Set this to 1 when used as cron)
* @param string $file 'auto' or filename to build
+ * @param int $keeplastnfiles Keep only last n files (not used yet)
* @return int 0 if OK, < 0 if KO (this function is used also by cron so only 0 is OK)
*/
- function dumpDatabase($compression='none', $type='auto', $usedefault=1, $file='auto')
+ function dumpDatabase($compression='none', $type='auto', $usedefault=1, $file='auto', $keeplastnfiles=0)
{
global $db, $conf, $langs, $dolibarr_main_data_root;
global $dolibarr_main_db_name, $dolibarr_main_db_host, $dolibarr_main_db_user, $dolibarr_main_db_port, $dolibarr_main_db_pass;
diff --git a/htdocs/core/modules/modCron.class.php b/htdocs/core/modules/modCron.class.php
index 73b27aae96b..bd5f193c568 100644
--- a/htdocs/core/modules/modCron.class.php
+++ b/htdocs/core/modules/modCron.class.php
@@ -102,7 +102,7 @@ class modCron extends DolibarrModules
// Cronjobs
$this->cronjobs = array(
0=>array('label'=>'PurgeDeleteTemporaryFilesShort', 'jobtype'=>'method', 'class'=>'core/class/utils.class.php', 'objectname'=>'Utils', 'method'=>'purgeFiles', 'parameters'=>'', 'comment'=>'PurgeDeleteTemporaryFiles', 'frequency'=>2, 'unitfrequency'=>3600 * 24 * 7, 'priority'=>10, 'status'=>1, 'test'=>true),
- 1=>array('label'=>'MakeLocalDatabaseDumpShort', 'jobtype'=>'method', 'class'=>'core/class/utils.class.php', 'objectname'=>'Utils', 'method'=>'dumpDatabase', 'parameters'=>'none', 'comment'=>'MakeLocalDatabaseDump', 'frequency'=>1, 'unitfrequency'=>3600 * 24 * 7, 'priority'=>20, 'status'=>0, 'test'=>in_array($db->type, array('mysql','mysqli'))),
+ 1=>array('label'=>'MakeLocalDatabaseDumpShort', 'jobtype'=>'method', 'class'=>'core/class/utils.class.php', 'objectname'=>'Utils', 'method'=>'dumpDatabase', 'parameters'=>'none,auto,1,auto,10', 'comment'=>'MakeLocalDatabaseDump', 'frequency'=>1, 'unitfrequency'=>3600 * 24 * 7, 'priority'=>20, 'status'=>0, 'test'=>in_array($db->type, array('mysql','mysqli'))),
// 1=>array('label'=>'My label', 'jobtype'=>'command', 'command'=>'', 'parameters'=>'', 'comment'=>'Comment', 'frequency'=>1, 'unitfrequency'=>3600*24)
);
diff --git a/htdocs/cron/class/cronjob.class.php b/htdocs/cron/class/cronjob.class.php
index e532f1e23e0..59a3d025386 100644
--- a/htdocs/cron/class/cronjob.class.php
+++ b/htdocs/cron/class/cronjob.class.php
@@ -959,7 +959,7 @@ class Cronjob extends CommonObject
// Create Object for the call module
$object = new $this->objectname($this->db);
- $params_arr = explode(", ",$this->params);
+ $params_arr = array_map('trim', explode(",",$this->params));
if (!is_array($params_arr))
{
$result = call_user_func(array($object, $this->methodename), $this->params);
diff --git a/htdocs/langs/en_US/cron.lang b/htdocs/langs/en_US/cron.lang
index 7ee76c03395..01b69b3b839 100644
--- a/htdocs/langs/en_US/cron.lang
+++ b/htdocs/langs/en_US/cron.lang
@@ -58,11 +58,11 @@ CronStatusInactiveBtn=Disable
CronTaskInactive=This job is disabled
CronId=Id
CronClassFile=Classes (filename.class.php)
-CronModuleHelp=Name of Dolibarr module directory (also work with external Dolibarr module).
For exemple to fetch method of Dolibarr Product object /htdocs/product/class/product.class.php, the value of module is product
-CronClassFileHelp=The file name to load.
For exemple to fetch method of Dolibarr Product object /htdocs/product/class/product.class.php, the value of class file name is product.class.php
-CronObjectHelp=The object name to load.
For exemple to fetch method of Dolibarr Product object /htdocs/product/class/product.class.php, the value of class file name is Product
-CronMethodHelp=The object method to launch.
For exemple to fetch method of Dolibarr Product object /htdocs/product/class/product.class.php, the value of method is is fecth
-CronArgsHelp=The method arguments.
For exemple to fetch method of Dolibarr Product object /htdocs/product/class/product.class.php, the value of paramters can be 0, ProductRef
+CronModuleHelp=Name of Dolibarr module directory (also work with external Dolibarr module).
For exemple to call the fetch method of Dolibarr Product object /htdocs/product/class/product.class.php, the value of module is product
+CronClassFileHelp=The file name to load.
For exemple to call the fetch method of Dolibarr Product object /htdocs/product/class/product.class.php, the value of class file name is product.class.php
+CronObjectHelp=The object name to load.
For exemple to call the fetch method of Dolibarr Product object /htdocs/product/class/product.class.php, the value of class file name is Product
+CronMethodHelp=The object method to launch.
For exemple to call the fetch method of Dolibarr Product object /htdocs/product/class/product.class.php, the value of method is is fecth
+CronArgsHelp=The method arguments.
For exemple to call the fetch method of Dolibarr Product object /htdocs/product/class/product.class.php, the value of paramters can be 0, ProductRef
CronCommandHelp=The system command line to execute.
CronCreateJob=Create new Scheduled Job
CronFrom=From