Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Browse files

MDL-31824 - Calendar - Fixing HTML classes fopr calendar month view -…

… patch provided by Mark Ward
  • Loading branch information...
commit 9e142d1121e8fe961896dff391f659a1a0a1a797 1 parent ecfe814
Jason Fowler phalacee authored
Showing with 5 additions and 5 deletions.
  1. +5 −5 calendar/renderer.php
10 calendar/renderer.php
View
@@ -460,7 +460,7 @@ public function show_month_detailed(calendar_information $calendar, moodle_url $
// Paddding (the first week may have blank days in the beginning)
for($i = $display->minwday; $i < $startwday; ++$i) {
$cell = new html_table_cell('&nbsp;');
- $cell->attributes = array('class'=>'nottoday');
+ $cell->attributes = array('class'=>'nottoday dayblank');
$row->cells[] = $cell;
}
@@ -519,10 +519,10 @@ public function show_month_detailed(calendar_information $calendar, moodle_url $
}
// Special visual fx for today
- if($display->thismonth && $calendar->day == $calendar->day) {
- $cellclasses[] = 'today';
+ if ($display->thismonth && $calendar->day == $date['mday']) {
+ $cellclasses[] = 'day today';
} else {
- $cellclasses[] = 'nottoday';
+ $cellclasses[] = 'day nottoday';
}
$cell->attributes = array('class'=>join(' ',$cellclasses));
@@ -553,7 +553,7 @@ public function show_month_detailed(calendar_information $calendar, moodle_url $
// Paddding (the last week may have blank days at the end)
for($i = $dayweek; $i <= $display->maxwday; ++$i) {
$cell = new html_table_cell('&nbsp;');
- $cell->attributes = array('class'=>'nottoday');
+ $cell->attributes = array('class'=>'nottoday dayblank');
$row->cells[] = $cell;
}
$table->data[] = $row;
Please sign in to comment.
Something went wrong with that request. Please try again.