NOBUG proper checking the value of checkbox elements

Without this patch, PHP generates notices as the variables representing
unchecked checkboxes are not defined at all in $data object.
This commit is contained in:
David Mudrak
2010-06-17 20:15:26 +00:00
parent d57599c1e1
commit c17e376337
+2 -2
View File
@@ -84,11 +84,11 @@
/// process data if submitted
//preprocess data
if ($data->enrolstartdisabled){
if (!empty($data->enrolstartdisabled)) {
$data->enrolstartdate = 0;
}
if ($data->enrolenddisabled) {
if (!empty($data->enrolenddisabled)) {
$data->enrolenddate = 0;
}