Exemple #1
0
define('CALENDAR_MONTH_STATE', CALENDAR_USE_MONTH_WEEKS);
if (!isset($_GET['year'])) {
    $_GET['year'] = date('Y');
}
$week_types = array('n_in_year', 'n_in_month');
if (!isset($_GET['week_type']) || !in_array($_GET['week_type'], $week_types)) {
    $_GET['week_type'] = 'n_in_year';
}
$Year = new Calendar_Year($_GET['year']);
$Year->build();
?>
<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0 Transitional//EN">
<html>
<head>
<title> <?php 
echo $Year->thisYear();
?>
 </title>
<style type="text/css">
body {
    font-family: Georgia, serif;
}
caption.year {
    font-weight: bold;
    font-size: 120%;
    font-color: navy;
}
caption.month {
    font-size: 110%;
    font-color: navy;
}
Exemple #2
0
 /**
  * Constructs a Link for a calendar to the given Year.
  *
  * @param Calendar_Year $year The calendar year to link to.
  */
 function _get_calendar_yearlink($year)
 {
     $next_year = $year->nextYear('object');
     return $_MIDCOM->get_context_data(MIDCOM_CONTEXT_ANCHORPREFIX) . 'archive/between/' . $year->thisYear() . '-01-01/' . $next_year->thisYear() . '-01-01/';
 }