add correct meta calendar
This commit is contained in:
@@ -9,7 +9,9 @@ class Calendar
|
||||
*/
|
||||
public static function getMonth($month, $year, $events = array())
|
||||
{
|
||||
$months = array(
|
||||
|
||||
|
||||
$months = array(
|
||||
1 => 'Январь',
|
||||
2 => 'Февраль',
|
||||
3 => 'Март',
|
||||
@@ -67,7 +69,7 @@ class Calendar
|
||||
$class = '';
|
||||
}
|
||||
|
||||
$event_show = false;
|
||||
/** $event_show = false;
|
||||
$event_text = '';
|
||||
$event_link = '';
|
||||
if (!empty($events)) {
|
||||
@@ -96,14 +98,24 @@ class Calendar
|
||||
$event_link = $text['link'];
|
||||
}
|
||||
}
|
||||
}
|
||||
} */
|
||||
|
||||
if ($day < 10)
|
||||
$day_str = "0$day";
|
||||
else
|
||||
$day_str = $day;
|
||||
|
||||
$arr_key = "$day_str.$month.$year";
|
||||
|
||||
|
||||
|
||||
if ($event_show) {
|
||||
//if ($event_show) {
|
||||
if (isset($events[$arr_key])) {
|
||||
|
||||
|
||||
$out.= '<td class="calendar-day ' . $class . ' calendar-event">';
|
||||
if (!empty($event_text)) {
|
||||
$out.= '<div class="calendar-popup" ><a href="'.$event_link.'" title="'.$event_text.'">'.$day.'</a></div>';
|
||||
}
|
||||
$out.= '<div class="calendar-popup" ><a href="'.$events[$arr_key]['link'].'" title="'.$events[$arr_key]['text'].'">'.$day.'</a></div>';
|
||||
|
||||
$out.= '</td>';
|
||||
} else {
|
||||
$out.= '<td class="calendar-day ' . $class . '">' . $day . '</td>';
|
||||
|
||||
Reference in New Issue
Block a user