File tree Expand file tree Collapse file tree 2 files changed +12
-12
lines changed
Expand file tree Collapse file tree 2 files changed +12
-12
lines changed Original file line number Diff line number Diff line change 1616//if ($_SESSION['user'] == 'admin') {
1717 if (!empty ($ _POST ['ok ' ])) {
1818 // Check input
19- if (empty ($ _POST ['v_min ' ])) $ errors [] = __ ('minute ' );
20- if (empty ($ _POST ['v_hour ' ])) $ errors [] = __ ('hour ' );
21- if (empty ($ _POST ['v_day ' ])) $ errors [] = __ ('day ' );
22- if (empty ($ _POST ['v_month ' ])) $ errors [] = __ ('month ' );
23- if (empty ($ _POST ['v_wday ' ])) $ errors [] = __ ('day of week ' );
24- if (empty ($ _POST ['v_cmd ' ])) $ errors [] = __ ('cmd ' );
19+ if (! isset ($ _POST ['v_min ' ])) $ errors [] = __ ('minute ' );
20+ if (! isset ($ _POST ['v_hour ' ])) $ errors [] = __ ('hour ' );
21+ if (! isset ($ _POST ['v_day ' ])) $ errors [] = __ ('day ' );
22+ if (! isset ($ _POST ['v_month ' ])) $ errors [] = __ ('month ' );
23+ if (! isset ($ _POST ['v_wday ' ])) $ errors [] = __ ('day of week ' );
24+ if (! isset ($ _POST ['v_cmd ' ])) $ errors [] = __ ('cmd ' );
2525
2626 // Protect input
2727 $ v_min = escapeshellarg ($ _POST ['v_min ' ]);
Original file line number Diff line number Diff line change 5252 </ tr >
5353 < tr >
5454 < td >
55- < input type ="text " size ="20 " class ="vst-input " name ="v_min " < ?php if (!empty ($v_min)) echo "value=".$v_min; ?> >
55+ < input type ="text " size ="20 " class ="vst-input " name ="v_min " < ?php if (isset ($v_min)) echo "value=".$v_min; ?> >
5656 </ td >
5757 </ tr >
5858 < tr >
6262 </ tr >
6363 < tr >
6464 < td >
65- < input type ="text " size ="20 " class ="vst-input " name ="v_hour " < ?php if (!empty ($v_hour)) echo "value=".$v_hour; ?> >
65+ < input type ="text " size ="20 " class ="vst-input " name ="v_hour " < ?php if (isset ($v_hour)) echo "value=".$v_hour; ?> >
6666 </ td >
6767 </ tr >
6868 < tr >
7272 </ tr >
7373 < tr >
7474 < td >
75- < input type ="text " size ="20 " class ="vst-input " name ="v_day " < ?php if (!empty ($v_day)) echo "value=".$v_day; ?> >
75+ < input type ="text " size ="20 " class ="vst-input " name ="v_day " < ?php if (isset ($v_day)) echo "value=".$v_day; ?> >
7676 </ td >
7777 </ tr >
7878 < tr >
8282 </ tr >
8383 < tr >
8484 < td >
85- < input type ="text " size ="20 " class ="vst-input " name ="v_month " < ?php if (!empty ($v_month)) echo "value=".$v_month; ?> >
85+ < input type ="text " size ="20 " class ="vst-input " name ="v_month " < ?php if (isset ($v_month)) echo "value=".$v_month; ?> >
8686 </ td >
8787 </ tr >
8888 < tr >
9292 </ tr >
9393 < tr >
9494 < td >
95- < input type ="text " size ="20 " class ="vst-input " name ="v_wday " < ?php if (!empty ($v_wday)) echo "value=".$v_wday; ?> >
95+ < input type ="text " size ="20 " class ="vst-input " name ="v_wday " < ?php if (isset ($v_wday)) echo "value=".$v_wday; ?> >
9696 </ td >
9797 </ tr >
9898 < tr >
102102 </ tr >
103103 < tr >
104104 < td >
105- < input type ="text " size ="20 " class ="vst-input " name ="v_cmd " < ?php if (!empty ($v_cmd)) echo "value='".$v_cmd."'"; ?> >
105+ < input type ="text " size ="20 " class ="vst-input " name ="v_cmd " < ?php if (isset ($v_cmd)) echo "value='".$v_cmd."'"; ?> >
106106 </ td >
107107 </ tr >
108108 </ table >
You can’t perform that action at this time.
0 commit comments