Created
July 16, 2013 19:32
-
-
Save chadsten/6011879 to your computer and use it in GitHub Desktop.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| <div class="<?php print $classes; ?>"<?php print $attributes; ?>> | |
| <?php if (!$label_hidden): ?> | |
| <div class="field-label"<?php print $title_attributes; ?>><?php print $label ?>: </div> | |
| <?php endif; ?> | |
| <div class="altered field-items"<?php print $content_attributes; ?>> | |
| <?php dpm($items); ?> | |
| <? | |
| list($start, $end) = explode(' to ', $items[0]['#markup']); | |
| list($start_date, $start_time) = explode(' ', $start); | |
| list($end_date, $end_time) = explode(' ', $end); | |
| $start = strtotime($start); | |
| echo format_date($start, 'custom', 'human_time'); | |
| ?> | |
| <div class="date-time-wrapper date"> | |
| <span class="date-time date from"><?= $start_date; ?></span> | |
| <?php if ($end_date && $start_date != $end_date) { ?> <span class="separator"> - </span><span class="date-time date to"><?= $end_date; ?></span> <?php } ?> | |
| </div> | |
| <div class="date-time-wrapper time"> | |
| <span class="date-time time from"><?= $start_time; ?></span> | |
| <?php if ($end_time) { ?><span class="separator"> - </span><span class="date-time time to"><?= $end_time; ?></span> <?php } ?> | |
| </div> | |
| </div> | |
| </div> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment