diff --git a/main/admin/calendar.lib.php b/main/admin/calendar.lib.php index 19c762e231..fd5a2329ee 100644 --- a/main/admin/calendar.lib.php +++ b/main/admin/calendar.lib.php @@ -1248,11 +1248,8 @@ function show_add_form($id = '') { $content=stripslashes($content); $title=stripslashes($title); // we start a completely new item, we do not come from the resource linker - if ($_GET['originalresource']!=="no" and $_GET['action']=="add") - { - - $_SESSION["formelements"]=null; - //unset_session_resources();//-------------------------------------------------------------------------------------- + if ($_GET['originalresource']!=="no" and $_GET['action']=="add") { + $_SESSION["formelements"]=null; } ?> diff --git a/main/calendar/agenda.lib.php b/main/calendar/agenda.lib.php index a7d53c72a2..4a48b972e8 100644 --- a/main/calendar/agenda.lib.php +++ b/main/calendar/agenda.lib.php @@ -693,13 +693,9 @@ class Agenda { * @author: Patrick Cool , Ghent University * @return html code */ - function construct_not_selected_select_form($group_list = null, $user_list = null, $to_already_selected = array()) { + static function construct_not_selected_select_form($group_list = null, $user_list = null, $to_already_selected = array()) { $html = ''; } } //end func toHtml @@ -525,7 +561,7 @@ class HTML_QuickForm_select extends HTML_QuickForm_element { if (is_array($this->_values)) { foreach ($this->_values as $key => $val) { for ($i = 0, $optCount = count($this->_options); $i < $optCount; $i++) { - if (0 == strcmp($val, $this->_options[$i]['attr']['value'])) { + if (0 == strcmp($val, $this->_options[$i]['attr']['value'])) { $value[$key] = $this->_options[$i]['text']; break; } @@ -572,7 +608,7 @@ class HTML_QuickForm_select extends HTML_QuickForm_element { $cleanValue = null; foreach ($value as $v) { for ($i = 0, $optCount = count($this->_options); $i < $optCount; $i++) { - if (0 == strcmp($v, $this->_options[$i]['attr']['value'])) { + if (0 == strcmp($v, $this->_options[$i]['attr']['value'])) { $cleanValue[] = $v; break; }