Projet

Général

Profil

Paste
Télécharger (1,83 ko) Statistiques
| Branche: | Révision:

root / drupal7 / sites / all / themes / adaptivetheme / at_core / templates / aggregator-item.tpl.php @ 74f6bef0

1
<?php
2
/**
3
 * @file
4
 * Adativetheme implementation to format an individual feed item for display
5
 * on the aggregator page.
6
 *
7
 * Adaptivetheme variables:
8
 * - $is_mobile: Mixed, requires the Mobile Detect or Browscap module to return
9
 *   TRUE for mobile.  Note that tablets are also considered mobile devices.  
10
 *   Returns NULL if the feature could not be detected.
11
 * - $is_tablet: Mixed, requires the Mobile Detect to return TRUE for tablets.
12
 *   Returns NULL if the feature could not be detected.
13
 *
14
 * Available variables:
15
 * - $feed_url: URL to the originating feed item.
16
 * - $feed_title: Title of the feed item.
17
 * - $source_url: Link to the local source section.
18
 * - $source_title: Title of the remote source.
19
 * - $source_date: Date the feed was posted on the remote source.
20
 * - $content: Feed item content.
21
 * - $categories: Linked categories assigned to the feed.
22
 *
23
 * @see template_preprocess()
24
 * @see template_preprocess_aggregator_item()
25
 * @see adaptivetheme_preprocess_aggregator_item()
26
 */
27
?>
28
<article class="<?php print $classes; ?>">
29

    
30
  <header>
31
    <h2<?php print $title_attributes; ?>>
32
      <a href="<?php print $feed_url; ?>"><?php print $feed_title; ?></a>
33
    </h2>
34
    <p class="feed-item-meta">
35
      <?php if ($source_url) : ?>
36
        <a href="<?php print $source_url; ?>" class="feed-item-source"><?php print $source_title; ?></a> -
37
      <?php endif; ?>
38
      <time datetime="<?php print $datetime; ?>"><?php print $source_date; ?></time>
39
    </p>
40
  </header>
41

    
42
  <?php if ($content) : ?>
43
    <div<?php print $content_attributes; ?>>
44
      <?php print $content; ?>
45
    </div>
46
  <?php endif; ?>
47

    
48
  <?php if ($categories): ?>
49
    <footer>
50
      <p class="feed-item-categories">
51
        <strong><?php print t('Categories'); ?></strong> - <?php print implode(', ', $categories); ?>
52
      </p>
53
    </footer>
54
  <?php endif; ?>
55

    
56
</article>