OSDN Git Service

初回コミット(v2.6.17.1)
[magic3/magic3.git] / templates / _system / html / com_content / frontpage / default_item.php
1 <?php
2 defined('_JEXEC') or die('Restricted access'); // no direct access
3 $canEdit = ($this->user->authorize('com_content', 'edit', 'content', 'all') || $this->user->authorize('com_content', 'edit', 'content', 'own'));
4 ?>
5 <?php if ($this->item->state == 0) : ?>
6 <div class="system-unpublished">
7 <?php endif; ?>
8
9 <div class="art-post">
10     <div class="art-post-body">
11 <div class="art-post-inner">
12 <?php
13 if ($this->item->params->get('show_title')) {
14  ob_start();
15 ?>
16  <h2 class="art-postheader"> 
17 <?php
18  artxFragmentBegin(ob_get_clean());
19  if ($this->item->params->get('link_titles') && $this->item->readmore_link != '')
20   artxFragmentContent('<a href="' . $this->item->readmore_link . '" class="PostHeader">' . $this->escape($this->item->title) . '</a>');
21  else
22   artxFragmentContent($this->escape($this->item->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->item->params->get('show_create_date')) {
35 artxFragment('', JHTML::_('date', $this->item->created, JText::_('DATE_FORMAT_LC2')), '', ' | ');
36 }
37 if (($this->item->params->get('show_author')) && ($this->item->author != "")) {
38   artxFragment('', JText::sprintf('Written by', ($this->item->created_by_alias ? $this->item->created_by_alias : $this->item->author)), '', ' | ');
39 }
40 if ($canEdit)
41   artxFragment('', JHTML::_('icon.edit', $this->item, $this->item->params, $this->access), '', ' | ');
42 artxFragmentEnd("\r\n</div>\r\n");
43 echo "<div class=\"art-postcontent\">\r\n    <!-- article-content -->\r\n";
44 if (!$this->item->params->get('show_intro'))
45  echo $this->item->event->afterDisplayTitle;
46 echo $this->item->event->beforeDisplayContent;
47 if (($this->item->params->get('show_section') && $this->item->sectionid) || ($this->item->params->get('show_category') && $this->item->catid)) {
48 ?>
49 <table class="contentpaneopen<?php echo $this->item->params->get('pageclass_sfx' ); ?>">
50 <tr>
51  <td>
52 <?php
53 if ($this->item->params->get('show_section') && $this->item->sectionid && isset($this->item->section)) {
54  echo "<span>";
55  if ($this->item->params->get('link_section'))
56   echo '<a href="'.JRoute::_(ContentHelperRoute::getSectionRoute($this->item->sectionid)).'">';
57  echo $this->item->section;
58  if ($this->item->params->get('link_section'))
59   echo '</a>';
60  if ($this->item->params->get('show_category'))
61   echo ' - ';
62  echo "</span>";
63 }
64 if ($this->item->params->get('show_category') && $this->item->catid) {
65  echo "<span>";
66  if ($this->item->params->get('link_category'))
67   echo '<a href="'.JRoute::_(ContentHelperRoute::getCategoryRoute($this->item->catslug, $this->item->sectionid)).'">';
68  echo $this->item->category;
69  if ($this->item->params->get('link_category'))
70   echo '</a>';
71  echo "</span>";
72 }
73 ?>
74  </td>
75 </tr>
76 </table>
77 <?php
78 }
79 if (isset ($this->item->toc))
80  echo $this->item->toc;
81 echo "<div class=\"art-article\">", $this->item->text, "</div>";
82 if (intval($this->item->modified) != 0 && $this->item->params->get('show_modify_date')) {
83  echo "<p class=\"modifydate\">";
84  echo JText::_('Last Updated') . ' (' . JHTML::_('date', $this->item->modified, JText::_('DATE_FORMAT_LC2')) . ')';
85  echo "</p>";
86 }
87 if ($this->item->params->get('show_readmore') && $this->item->readmore) {
88 ?>
89 <p>
90  <span class="art-button-wrapper">
91   <span class="l"> </span>
92   <span class="r"> </span>
93   <a class="readon art-button" href="<?php echo $this->item->readmore_link; ?>">
94   <?php
95    if ($this->item->readmore_register) {
96     echo str_replace(' ', '&nbsp;', JText::_('Register to read more...'));
97    } elseif ($readmore = $this->item->params->get('readmore')){ 
98     echo str_replace(' ', '&nbsp;', $readmore);
99    } else {
100     echo str_replace(' ', '&nbsp;', JText::sprintf('Read more...'));
101    }
102   ?>
103   </a>
104  </span>
105 </p>
106 <?php
107 }
108 echo "<span class=\"article_separator\">&nbsp;</span>";
109 echo $this->item->event->afterDisplayContent;
110 echo "\r\n    <!-- /article-content -->\r\n</div>\r\n<div class=\"cleared\"></div>\r\n";
111 ?>
112
113 </div>
114
115                 <div class="cleared"></div>
116     </div>
117 </div>
118
119
120 <?php if ($this->item->state == 0) : ?>
121 </div>
122 <?php endif; ?>