OSDN Git Service

初回コミット(v2.6.17.1)
[magic3/magic3.git] / templates / _system / html / com_content / article / default.php
1 <?php
2 defined('_JEXEC') or die('Restricted access'); // no direct access
3 require_once dirname(__FILE__) . str_replace('/', DIRECTORY_SEPARATOR, '/../../../functions.php');
4
5 $canEdit = ($this->user->authorize('com_content', 'edit', 'content', 'all') || $this->user->authorize('com_content', 'edit', 'content', 'own'));
6
7 echo artxPost(artxPageTitle($this, $this->params->get('show_page_title', 1) && $this->params->get('page_title') != $this->article->title), null);
8 ?>
9 <div class="art-post">
10     <div class="art-post-body">
11 <div class="art-post-inner">
12 <?php
13 if ($this->params->get('show_title')) {
14  ob_start();
15 ?>
16  <h2 class="art-postheader"> 
17 <?php
18  artxFragmentBegin(ob_get_clean());
19  if ($this->params->get('link_titles') && $this->article->readmore_link != '')
20   artxFragmentContent('<a href="' . $this->article->readmore_link . '" class="PostHeader">' . $this->escape($this->article->title) . '</a>');
21  else
22   artxFragmentContent($this->escape($this->article->title));
23  ob_start();
24 ?>
25
26 </h2>
27
28 <?php
29  artxFragmentEnd(ob_get_clean());
30 }
31 artxFragmentBegin("<div class=\"art-postheadericons art-metadata-icons\">\r\n");
32   if ($this->params->get('show_url') && $this->article->urls)
33    artxFragment('', '<a href="http://' . $this->item->urls . '" target="_blank">' . $this->item->urls . '</a>', '', ' | ');
34 if ($this->params->get('show_create_date')) {
35   artxFragment('', JHTML::_('date', $this->article->created, JText::_('DATE_FORMAT_LC2')), '', ' | ');
36 }
37 if (($this->params->get('show_author')) && ($this->article->author != "")) {
38   artxFragment('', JText::sprintf('Written by', ($this->article->created_by_alias ? $this->article->created_by_alias : $this->article->author)), '', ' | ');
39 }
40 if (!$this->print && $canEdit)
41  artxFragment('', JHTML::_('icon.edit', $this->article, $this->params, $this->access), '', ' | ');
42
43 if ($this->print)
44  artxFragment('', JHTML::_('icon.print_screen',  $this->article, $this->params, $this->access, array('class' => 'art-metadata-icon')), '', ' | ');
45 artxFragmentEnd("\r\n</div>\r\n");
46 echo "<div class=\"art-postcontent\">\r\n    <!-- article-content -->\r\n";
47 if (!$this->params->get('show_intro'))
48  echo $this->article->event->afterDisplayTitle;
49 echo $this->article->event->beforeDisplayContent;
50 if (($this->params->get('show_section') && $this->article->sectionid) || ($this->params->get('show_category') && $this->article->catid)) {
51 ?>
52 <table class="contentpaneopen<?php echo $this->params->get('pageclass_sfx' ); ?>">
53 <tr>
54         <td>
55 <?php
56 if ($this->params->get('show_section') && $this->article->sectionid && isset($this->article->section)) {
57  echo "<span>";
58  if ($this->params->get('link_section'))
59   echo '<a href="'.JRoute::_(ContentHelperRoute::getSectionRoute($this->article->sectionid)).'">';
60  echo $this->article->section;
61  if ($this->params->get('link_section'))
62   echo '</a>';
63  if ($this->params->get('show_category'))
64   echo ' - ';
65  echo "</span>";
66 }
67 if ($this->params->get('show_category') && $this->article->catid) {
68  echo "<span>";
69  if ($this->params->get('link_category'))
70   echo '<a href="'.JRoute::_(ContentHelperRoute::getCategoryRoute($this->article->catslug, $this->article->sectionid)).'">';
71  echo $this->article->category;
72  if ($this->params->get('link_category'))
73   echo '</a>';
74  echo "</span>";
75 }
76 ?>
77         </td>
78 </tr>
79 </table>
80 <?php
81 }
82 if (isset ($this->article->toc))
83  echo $this->article->toc;
84 echo "<div class=\"art-article\">";
85 echo $this->article->text;
86 echo "</div>";
87 if (intval($this->article->modified) !=0 && $this->params->get('show_modify_date')) {
88  echo "<p class=\"modifydate\">";
89  echo JText::_('Last Updated' ) . ' (' . JHTML::_('date', $this->article->modified, JText::_('DATE_FORMAT_LC2')) . ')';
90  echo "</p>";
91 }
92 echo "<span class=\"article_separator\">&nbsp;</span>";
93 echo $this->article->event->afterDisplayContent;
94 echo "\r\n    <!-- /article-content -->\r\n</div>\r\n<div class=\"cleared\"></div>\r\n";
95 ?>
96
97 </div>
98
99                 <div class="cleared"></div>
100     </div>
101 </div>
102