Fix for bug 1527:

The New Event button is back in day view. Silly mistake, $USER wasn't taken
from the globals and thus it always thought you weren't logged in.
This commit is contained in:
defacer 2004-06-23 09:53:23 +00:00
parent 1cbcc2c3d0
commit b1bd2cf0c1

View File

@ -183,7 +183,7 @@
function calendar_show_day($d, $m, $y, $courses, $groups, $users) {
global $CFG, $THEME, $db;
global $CFG, $THEME, $USER, $db;
if (!checkdate($m, $d, $y)) {
$now = usergetdate(time());
@ -200,7 +200,6 @@ function calendar_show_day($d, $m, $y, $courses, $groups, $users) {
// New event button
if (empty($USER) || isguest()) {
$text = get_string('dayview', 'calendar').': '.calendar_course_filter_selector($getvars);
} else {
$text = '<div style="float: left;">'.get_string('dayview', 'calendar').': '.
calendar_course_filter_selector($getvars).'</div><div style="float: right;">';