2 defined('_JEXEC') or die;
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');
12 $component = new ArtxContent15($this, $this->params);
13 $article = $component->articleListItem($this->item);
17 if ($this->item->state == 0)
18 echo '<div class="system-unpublished">';
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;
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
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();
66 echo $article->article($params);
69 if ($this->item->state == 0)