[ Index ]

PHP Cross Reference of Drupal 6 (yi-drupal)

title

Body

[close]

/sites/all/modules/calendar/calendar_multiday/theme/ -> calendar-month-node.tpl.php (source)

   1  <?php
   2  // $Id: calendar-month-node.tpl.php,v 1.1.2.2 2010/12/31 23:31:28 karens Exp $
   3  /**
   4   * @file
   5   * Template to display a view item as a calendar month node.
   6   * 
   7   * $node 
   8   *   A node object for this calendar item. Note this is
   9   *   not a complete node object, but it will have $node->nid
  10   *   that you can use to load the full object, and
  11   *   $node->type to tell the content type of the node.
  12   * 
  13   * $fields
  14   *   An array of information for every field selected in the 'Fields'
  15   *   section of this view, formatted as requested in the View setup.
  16   * 
  17   * Calendar info for this individual calendar item is in local time --
  18   * the user timezone where configurable timezones are allowed and set,
  19   * otherwise the site timezone. If this item has extends over more than
  20   * one day, it has been broken apart into separate nodes for each calendar
  21   * date and calendar_start will be no earlier than the start of
  22   * the current day and calendar_end will be no later than the end
  23   * of the current day.
  24   * 
  25   * $calendar_start - A formatted datetime start date for this item.
  26   *   i.e. '2008-05-12 05:26:15'.
  27   * $calendar_end - A formatted datetime end date for this item,
  28   *   the same as the start date except for fields that have from/to
  29   *   fields defined, like Date module dates. 
  30   * $calendar_start_date - a PHP date object for the start time.
  31   * $calendar_end_date - a PHP date object for the end time.
  32   * 
  33   * You can use PHP date functions on the date object to display date
  34   * information in other ways, like:
  35   * 
  36   *   print date_format($calendar_start_date, 'l, j F Y - g:ia');
  37   * 
  38   * @see template_preprocess_calendar_month_node.
  39   */
  40  $index = 0;
  41  ?>
  42  <div class="view-item view-item-<?php print $view->name ?>">
  43    <div class="calendar monthview">
  44      <?php print theme('calendar_stripe_stripe', $node); ?>
  45      <div class="<?php print $node->date_id ?> contents">
  46        <?php foreach ($fields as $field): ?>
  47          <?php if ($index++ == 0 && (isset($node->continuation) && $node->continuation)) : ?>
  48          <div class="continuation">&laquo;</div>
  49          <?php endif;?>
  50          <div id="<?php print $field['id']; ?>" class="view-field view-data-<?php print $field['id'] ?>">
  51            <?php if ($field['label']): ?>
  52              <div class="view-label-<?php print $field['id'] ?>"><?php print $field['label'] ?></div>
  53            <?php endif; ?>  
  54            <?php print $field['data']; ?>
  55          </div>  
  56        <?php endforeach; ?>
  57      </div>  
  58      <?php if (isset($node->continues) && $node->continues) : ?>
  59      <div class="continues">&raquo;</div>
  60      <?php else : ?>
  61      <div class="cutoff">&nbsp;</div>
  62      <?php endif;?>
  63    </div>    
  64  </div>


Generated: Mon Jul 9 18:01:44 2012 Cross-referenced by PHPXref 0.7