OSDN Git Service

初回コミット(v2.6.17.1)
[magic3/magic3.git] / templates / art26_test2 / html / com_content / category / blog_item.php
1 <?php
2 defined('_JEXEC') or die;
3
4 // Create component view for Joomla! 1.5 or 1.6.
5 // The classes are defined in ../../../functions.php file and encapsulate 
6 // version-specific queries and formatting.
7 if ($GLOBALS['version']->RELEASE == '1.6') {
8     $component = new ArtxContent16($this, $this->params);
9     $article = $component->articleListItem($this->item);
10     JHtml::addIncludePath(JPATH_COMPONENT . DS . 'helpers');
11 } else {
12     $component = new ArtxContent15($this, $this->params);
13     $article = $component->articleListItem($this->item);
14 }
15
16
17 if ($this->item->state == 0)
18  echo '<div class="system-unpublished">';
19
20
21 $params = $article->getArticleViewParameters();
22 if ($article->titleVisible) {
23     $params['header-text'] = $this->escape($article->title);
24     if (strlen($article->titleLink))
25         $params['header-link'] = $article->titleLink;
26 }
27 // Change the order of "if" statements to change the order of article metadata header items.
28 if ($article->showCreateDate)
29     $params['metadata-header-icons'][] = JHTML::_('image.site', 'postdateicon.png', null, null, null, JText::_("postdateicon"), array('width' => '17', 'height' => '18', 'class' => 'art-metadata-icon')) . $article->createDateInfo();
30 if ($article->showModifyDate)
31     $params['metadata-header-icons'][] = JHTML::_('image.site', 'postdateicon.png', null, null, null, JText::_("postdateicon"), array('width' => '17', 'height' => '18', 'class' => 'art-metadata-icon')) . $article->modifyDateInfo();
32 if ($article->showPublishDate)
33     $params['metadata-header-icons'][] = JHTML::_('image.site', 'postdateicon.png', null, null, null, JText::_("postdateicon"), array('width' => '17', 'height' => '18', 'class' => 'art-metadata-icon')) . $article->publishDateInfo();
34 if ($article->showAuthor)
35     $params['metadata-header-icons'][] = JHTML::_('image.site', 'postauthoricon.png', null, null, null, JText::_("postauthoricon"), array('width' => '14', 'height' => '14', 'class' => 'art-metadata-icon')) . $article->authorInfo();
36 if (!$article->print && $article->showPdfIcon)
37     $params['metadata-header-icons'][] = $article->pdfIcon();
38 if ($article->showPrintIcon)
39     $params['metadata-header-icons'][] = $article->print ? $article->printScreenIcon() : $article->printPopupIcon();
40 if ($article->showEmailIcon)
41     $params['metadata-header-icons'][] = $article->emailIcon();
42 if (!$article->print && $article->canEdit)
43     $params['metadata-header-icons'][] = $article->editIcon();
44 if ($article->showHits && $article->hits)
45     $params['metadata-header-icons'][] = $article->hitsInfo();
46 if ($article->showUrl)
47     $params['metadata-header-icons'][] = $article->urlInfo();
48 // Build article content
49 $content = '';
50 if (!$article->isPublished)
51     $content .= $article->beginUnpublishedArticle();
52 if (!$article->showIntro)
53     $content .= $article->event('afterDisplayTitle');
54 $content .= $article->event('beforeDisplayContent');
55 $content .= $article->introText();
56 if ($article->showReadmore)
57     $content .= $article->readmore();
58 $content .= $article->event('afterDisplayContent');
59 if (!$article->isPublished)
60     $content .= $article->endUnpublishedArticle();
61 $params['content'] = $content;
62 // Change the order of "if" statements to change the order of article metadata footer items.
63 if ($article->showParentCategory || $article->showCategory)
64   $params['metadata-footer-icons'][] = JHTML::_('image.site', 'postcategoryicon.png', null, null, null, JText::_("postcategoryicon"), array('width' => '18', 'height' => '18', 'class' => 'art-metadata-icon')) . $article->categories();
65 // Render article
66 echo $article->article($params);
67
68
69 if ($this->item->state == 0)
70  echo '</div>';