
<table class="minicalendar">
<thead>
  <tr>
    <th class="head previous"><?php if ($this->prevHref): ?><a href="<?= $this->prevHref ?>" rel="nofollow" title="<?= $this->prevTitle ?>"><?= $this->prevLabel ?></a><?php else: ?>&nbsp;<?php endif; ?></th>
    <th colspan="5" class="head current"><?= $this->current ?></th>
    <th class="head next"><?php if ($this->nextHref): ?><a href="<?= $this->nextHref ?>" rel="nofollow" title="<?= $this->nextTitle ?>"><?= $this->nextLabel ?></a><?php else: ?>&nbsp;<?php endif; ?></th>
  </tr>
  <tr>
    <?php foreach ($this->days as $i=>$day): ?>
      <th class="label<?= $day['class'] ?>"><?= utf8_substr($day['name'], 0, $this->substr) ?><span class="invisible"><?= utf8_substr($day['name'], $this->substr) ?></span></th>
    <?php endforeach; ?>
  </tr>
</thead>
<tbody>
  <?php foreach ($this->weeks as $class=>$week): ?>
    <tr class="<?= $class ?>">
      <?php foreach ($week as $day): ?>
        <?php if ($day['href']): ?>
          <td class="<?= $day['class'] ?>"><a href="<?= $day['href'] ?>" title="<?= $day['title'] ?>"><?= $day['label'] ?></a></td>
        <?php else: ?>
          <td class="<?= $day['class'] ?>"><?= $day['label'] ?></td>
        <?php endif; ?>
      <?php endforeach; ?>
    </tr>
  <?php endforeach; ?>
</tbody>
</table>
