diff --git a/web/add/cron/index.php b/web/add/cron/index.php index f2fd6bf9..b8790ebc 100644 --- a/web/add/cron/index.php +++ b/web/add/cron/index.php @@ -16,12 +16,12 @@ top_panel($user,$TAB); //if ($_SESSION['user'] == 'admin') { if (!empty($_POST['ok'])) { // Check input - if (empty($_POST['v_min'])) $errors[] = __('minute'); - if (empty($_POST['v_hour'])) $errors[] = __('hour'); - if (empty($_POST['v_day'])) $errors[] = __('day'); - if (empty($_POST['v_month'])) $errors[] = __('month'); - if (empty($_POST['v_wday'])) $errors[] = __('day of week'); - if (empty($_POST['v_cmd'])) $errors[] = __('cmd'); + if (!isset($_POST['v_min'])) $errors[] = __('minute'); + if (!isset($_POST['v_hour'])) $errors[] = __('hour'); + if (!isset($_POST['v_day'])) $errors[] = __('day'); + if (!isset($_POST['v_month'])) $errors[] = __('month'); + if (!isset($_POST['v_wday'])) $errors[] = __('day of week'); + if (!isset($_POST['v_cmd'])) $errors[] = __('cmd'); // Protect input $v_min = escapeshellarg($_POST['v_min']); diff --git a/web/templates/admin/edit_cron.html b/web/templates/admin/edit_cron.html index 9be88c14..45dd5839 100644 --- a/web/templates/admin/edit_cron.html +++ b/web/templates/admin/edit_cron.html @@ -52,7 +52,7 @@