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 $version = new JVersion();
8 if ($version->RELEASE == '1.5') {
9 $component = new ArtxContent15($this, $this->params);
10 $article = $component->articleListItem($this->item);
12 $component = new ArtxContent16($this, $this->params);
13 $article = $component->articleListItem($this->item);
14 JHtml::addIncludePath(JPATH_COMPONENT . DS . 'helpers');
18 if ($this->item->state == 0)
19 echo '<div class="system-unpublished">';
22 $params = $article->getArticleViewParameters();
23 if ($article->titleVisible) {
24 $params['header-text'] = $this->escape($article->title);
25 if (strlen($article->titleLink))
26 $params['header-link'] = $article->titleLink;
28 // Change the order of "if" statements to change the order of article metadata header items.
29 if ($article->showCreateDate)
30 $params['metadata-header-icons'][] = $article->createDateInfo();
31 if ($article->showModifyDate)
32 $params['metadata-header-icons'][] = $article->modifyDateInfo();
33 if ($article->showPublishDate)
34 $params['metadata-header-icons'][] = $article->publishDateInfo();
35 if ($article->showAuthor)
36 $params['metadata-header-icons'][] = $article->authorInfo();
37 if (!$article->print && $article->showPdfIcon)
38 $params['metadata-header-icons'][] = $article->pdfIcon();
39 if ($article->showPrintIcon)
40 $params['metadata-header-icons'][] = $article->print ? $article->printScreenIcon() : $article->printPopupIcon();
41 if (!$article->print && $article->showEmailIcon)
42 $params['metadata-header-icons'][] = $article->emailIcon();
43 if (!$article->print && $article->canEdit)
44 $params['metadata-header-icons'][] = $article->editIcon();
45 if ($article->showHits && $article->hits)
46 $params['metadata-header-icons'][] = $article->hitsInfo();
47 if ($article->showUrl)
48 $params['metadata-header-icons'][] = $article->urlInfo();
49 // Build article content
51 if (!$article->isPublished)
52 $content .= $article->beginUnpublishedArticle();
53 if (!$article->showIntro)
54 $content .= $article->event('afterDisplayTitle');
55 $content .= $article->event('beforeDisplayContent');
56 $content .= $article->introText();
57 if ($article->showReadmore)
58 $content .= $article->readmore();
59 $content .= $article->event('afterDisplayContent');
60 if (!$article->isPublished)
61 $content .= $article->endUnpublishedArticle();
62 $params['content'] = $content;
63 // Change the order of "if" statements to change the order of article metadata footer items.
64 if ($article->showParentCategory || $article->showCategory)
65 $params['metadata-footer-icons'][] = $article->categories();
67 echo $article->article($params);
70 if ($this->item->state == 0)