mirror of
https://github.com/e107inc/e107.git
synced 2025-08-04 13:47:31 +02:00
Possible fix for cron descriptions containing single quotes not appearing in database correctly.
This commit is contained in:
@@ -194,13 +194,15 @@ class cron_admin_ui extends e_admin_ui
|
|||||||
/**
|
/**
|
||||||
* Import Cron Settings into Database.
|
* Import Cron Settings into Database.
|
||||||
*/
|
*/
|
||||||
public function cronImport($new_cron = FALSE)
|
public function cronImport($new_cron = array())
|
||||||
{
|
{
|
||||||
if(!$new_cron)
|
if(empty($new_cron))
|
||||||
{
|
{
|
||||||
return;
|
return null;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
$tp = e107::getParser();
|
||||||
|
|
||||||
foreach($new_cron as $class => $ecron)
|
foreach($new_cron as $class => $ecron)
|
||||||
{
|
{
|
||||||
foreach($ecron as $val)
|
foreach($ecron as $val)
|
||||||
@@ -209,7 +211,7 @@ class cron_admin_ui extends e_admin_ui
|
|||||||
'cron_id' => 0,
|
'cron_id' => 0,
|
||||||
'cron_name' => $val['name'],
|
'cron_name' => $val['name'],
|
||||||
'cron_category' => $val['category'],
|
'cron_category' => $val['category'],
|
||||||
'cron_description' => $val['description'],
|
'cron_description' => $tp->toDB($val['description']),
|
||||||
'cron_function' => $class."::".$val['function'],
|
'cron_function' => $class."::".$val['function'],
|
||||||
'cron_tab' => varset($val['tab'], '* * * * *'),
|
'cron_tab' => varset($val['tab'], '* * * * *'),
|
||||||
'cron_active' => varset($val['active'], '0'),
|
'cron_active' => varset($val['active'], '0'),
|
||||||
|
Reference in New Issue
Block a user