| Current Path : /home/wuectly/www/03cbe/ |
| Current File : /home/wuectly/www/03cbe/article.tar |
view.html.php 0000604 00000024244 15245536013 0007200 0 ustar 00 <?php
/**
* @package Joomla.Site
* @subpackage com_content
*
* @copyright (C) 2006 Open Source Matters, Inc. <https://www.joomla.org>
* @license GNU General Public License version 2 or later; see LICENSE.txt
*/
defined('_JEXEC') or die;
/**
* HTML Article View class for the Content component
*
* @since 1.5
*/
class ContentViewArticle extends JViewLegacy
{
protected $item;
protected $params;
protected $print;
protected $state;
protected $user;
/**
* Execute and display a template script.
*
* @param string $tpl The name of the template file to parse; automatically searches through the template paths.
*
* @return mixed A string if successful, otherwise an Error object.
*/
public function display($tpl = null)
{
$app = JFactory::getApplication();
$user = JFactory::getUser();
$dispatcher = JEventDispatcher::getInstance();
$this->item = $this->get('Item');
$this->print = $app->input->getBool('print');
$this->state = $this->get('State');
$this->user = $user;
// Check for errors.
if (count($errors = $this->get('Errors')))
{
JError::raiseWarning(500, implode("\n", $errors));
return false;
}
// Create a shortcut for $item.
$item = $this->item;
$item->tagLayout = new JLayoutFile('joomla.content.tags');
// Add router helpers.
$item->slug = $item->alias ? ($item->id . ':' . $item->alias) : $item->id;
$item->catslug = $item->category_alias ? ($item->catid . ':' . $item->category_alias) : $item->catid;
$item->parent_slug = $item->parent_alias ? ($item->parent_id . ':' . $item->parent_alias) : $item->parent_id;
// No link for ROOT category
if ($item->parent_alias === 'root')
{
$item->parent_slug = null;
}
// TODO: Change based on shownoauth
$item->readmore_link = JRoute::_(ContentHelperRoute::getArticleRoute($item->slug, $item->catid, $item->language));
// Merge article params. If this is single-article view, menu params override article params
// Otherwise, article params override menu item params
$this->params = $this->state->get('params');
$active = $app->getMenu()->getActive();
$temp = clone $this->params;
// Check to see which parameters should take priority
if ($active)
{
$currentLink = $active->link;
// If the current view is the active item and an article view for this article, then the menu item params take priority
if (strpos($currentLink, 'view=article') && strpos($currentLink, '&id=' . (string) $item->id))
{
// Load layout from active query (in case it is an alternative menu item)
if (isset($active->query['layout']))
{
$this->setLayout($active->query['layout']);
}
// Check for alternative layout of article
elseif ($layout = $item->params->get('article_layout'))
{
$this->setLayout($layout);
}
// $item->params are the article params, $temp are the menu item params
// Merge so that the menu item params take priority
$item->params->merge($temp);
}
else
{
// Current view is not a single article, so the article params take priority here
// Merge the menu item params with the article params so that the article params take priority
$temp->merge($item->params);
$item->params = $temp;
// Check for alternative layouts (since we are not in a single-article menu item)
// Single-article menu item layout takes priority over alt layout for an article
if ($layout = $item->params->get('article_layout'))
{
$this->setLayout($layout);
}
}
}
else
{
// Merge so that article params take priority
$temp->merge($item->params);
$item->params = $temp;
// Check for alternative layouts (since we are not in a single-article menu item)
// Single-article menu item layout takes priority over alt layout for an article
if ($layout = $item->params->get('article_layout'))
{
$this->setLayout($layout);
}
}
$offset = $this->state->get('list.offset');
// Check the view access to the article (the model has already computed the values).
if ($item->params->get('access-view') == false && ($item->params->get('show_noauth', '0') == '0'))
{
$app->enqueueMessage(JText::_('JERROR_ALERTNOAUTHOR'), 'error');
$app->setHeader('status', 403, true);
return;
}
/**
* Check for no 'access-view' and empty fulltext,
* - Redirect guest users to login
* - Deny access to logged users with 403 code
* NOTE: we do not recheck for no access-view + show_noauth disabled ... since it was checked above
*/
if ($item->params->get('access-view') == false && !strlen($item->fulltext))
{
if ($this->user->get('guest'))
{
$return = base64_encode(JUri::getInstance());
$login_url_with_return = JRoute::_('index.php?option=com_users&view=login&return=' . $return);
$app->enqueueMessage(JText::_('JERROR_ALERTNOAUTHOR'), 'notice');
$app->redirect($login_url_with_return, 403);
}
else
{
$app->enqueueMessage(JText::_('JERROR_ALERTNOAUTHOR'), 'error');
$app->setHeader('status', 403, true);
return;
}
}
/**
* NOTE: The following code (usually) sets the text to contain the fulltext, but it is the
* responsibility of the layout to check 'access-view' and only use "introtext" for guests
*/
if ($item->params->get('show_intro', '1') == '1')
{
$item->text = $item->introtext . ' ' . $item->fulltext;
}
elseif ($item->fulltext)
{
$item->text = $item->fulltext;
}
else
{
$item->text = $item->introtext;
}
$item->tags = new JHelperTags;
$item->tags->getItemTags('com_content.article', $this->item->id);
if ($item->params->get('show_associations'))
{
$item->associations = ContentHelperAssociation::displayAssociations($item->id);
}
// Process the content plugins.
JPluginHelper::importPlugin('content');
$dispatcher->trigger('onContentPrepare', array ('com_content.article', &$item, &$item->params, $offset));
$item->event = new stdClass;
$results = $dispatcher->trigger('onContentAfterTitle', array('com_content.article', &$item, &$item->params, $offset));
$item->event->afterDisplayTitle = trim(implode("\n", $results));
$results = $dispatcher->trigger('onContentBeforeDisplay', array('com_content.article', &$item, &$item->params, $offset));
$item->event->beforeDisplayContent = trim(implode("\n", $results));
$results = $dispatcher->trigger('onContentAfterDisplay', array('com_content.article', &$item, &$item->params, $offset));
$item->event->afterDisplayContent = trim(implode("\n", $results));
// Escape strings for HTML output
$this->pageclass_sfx = htmlspecialchars($this->item->params->get('pageclass_sfx', ''));
$this->_prepareDocument();
parent::display($tpl);
}
/**
* Prepares the document.
*
* @return void
*/
protected function _prepareDocument()
{
$app = JFactory::getApplication();
$menus = $app->getMenu();
$pathway = $app->getPathway();
$title = null;
/**
* Because the application sets a default page title,
* we need to get it from the menu item itself
*/
$menu = $menus->getActive();
if ($menu)
{
$this->params->def('page_heading', $this->params->get('page_title', $menu->title));
}
else
{
$this->params->def('page_heading', JText::_('JGLOBAL_ARTICLES'));
}
$title = $this->params->get('page_title', '');
$id = (int) @$menu->query['id'];
// If the menu item does not concern this article
if ($menu && (!isset($menu->query['option']) || $menu->query['option'] !== 'com_content' || $menu->query['view'] !== 'article'
|| $id != $this->item->id))
{
// If a browser page title is defined, use that, then fall back to the article title if set, then fall back to the page_title option
$title = $this->item->params->get('article_page_title', $this->item->title ?: $title);
$path = array(array('title' => $this->item->title, 'link' => ''));
$category = JCategories::getInstance('Content')->get($this->item->catid);
while ($category && (!isset($menu->query['option']) || $menu->query['option'] !== 'com_content' || $menu->query['view'] === 'article'
|| $id != $category->id) && $category->id !== 'root')
{
$path[] = array('title' => $category->title, 'link' => ContentHelperRoute::getCategoryRoute($category->id));
$category = $category->getParent();
}
$path = array_reverse($path);
foreach ($path as $item)
{
$pathway->addItem($item['title'], $item['link']);
}
}
// Check for empty title and add site name if param is set
if (empty($title))
{
$title = $app->get('sitename');
}
elseif ($app->get('sitename_pagetitles', 0) == 1)
{
$title = JText::sprintf('JPAGETITLE', $app->get('sitename'), $title);
}
elseif ($app->get('sitename_pagetitles', 0) == 2)
{
$title = JText::sprintf('JPAGETITLE', $title, $app->get('sitename'));
}
if (empty($title))
{
$title = $this->item->title;
}
$this->document->setTitle($title);
if ($this->item->metadesc)
{
$this->document->setDescription($this->item->metadesc);
}
elseif ($this->params->get('menu-meta_description'))
{
$this->document->setDescription($this->params->get('menu-meta_description'));
}
if ($this->item->metakey)
{
$this->document->setMetadata('keywords', $this->item->metakey);
}
elseif ($this->params->get('menu-meta_keywords'))
{
$this->document->setMetadata('keywords', $this->params->get('menu-meta_keywords'));
}
if ($this->params->get('robots'))
{
$this->document->setMetadata('robots', $this->params->get('robots'));
}
if ($app->get('MetaAuthor') == '1')
{
$author = $this->item->created_by_alias ?: $this->item->author;
$this->document->setMetaData('author', $author);
}
$mdata = $this->item->metadata->toArray();
foreach ($mdata as $k => $v)
{
if ($v)
{
$this->document->setMetadata($k, $v);
}
}
// If there is a pagebreak heading or title, add it to the page title
if (!empty($this->item->page_title))
{
$this->item->title = $this->item->title . ' - ' . $this->item->page_title;
$this->document->setTitle(
$this->item->page_title . ' - ' . JText::sprintf('PLG_CONTENT_PAGEBREAK_PAGE_NUM', $this->state->get('list.offset') + 1)
);
}
if ($this->print)
{
$this->document->setMetaData('robots', 'noindex, nofollow');
}
}
}
tmpl/default.xml 0000604 00000016540 15245536013 0007674 0 ustar 00 <?xml version="1.0" encoding="utf-8"?>
<metadata>
<layout title="COM_CONTENT_ARTICLE_VIEW_DEFAULT_TITLE" option="COM_CONTENT_ARTICLE_VIEW_DEFAULT_OPTION">
<help
key = "JHELP_MENUS_MENU_ITEM_ARTICLE_SINGLE_ARTICLE"
/>
<message>
<![CDATA[COM_CONTENT_ARTICLE_VIEW_DEFAULT_DESC]]>
</message>
</layout>
<!-- Add fields to the request variables for the layout. -->
<fields name="request">
<fieldset name="request"
addfieldpath="/administrator/components/com_content/models/fields">
<field
name="id"
type="modal_article"
label="COM_CONTENT_FIELD_SELECT_ARTICLE_LABEL"
description="COM_CONTENT_FIELD_SELECT_ARTICLE_DESC"
required="true"
select="true"
new="true"
edit="true"
clear="true"
/>
</fieldset>
</fields>
<!-- Add fields to the parameters object for the layout. -->
<fields name="params">
<!-- Basic options. -->
<fieldset name="basic"
label="COM_CONTENT_ATTRIBS_ARTICLE_SETTINGS_LABEL">
<field
name="show_title"
type="list"
label="JGLOBAL_SHOW_TITLE_LABEL"
description="JGLOBAL_SHOW_TITLE_DESC"
useglobal="true"
class="chzn-color"
>
<option value="1">JSHOW</option>
<option value="0">JHIDE</option>
</field>
<field
name="link_titles"
type="list"
label="JGLOBAL_LINKED_TITLES_LABEL"
description="JGLOBAL_LINKED_TITLES_DESC"
useglobal="true"
class="chzn-color"
>
<option value="1">JYES</option>
<option value="0">JNO</option>
</field>
<field
name="show_intro"
type="list"
label="JGLOBAL_SHOW_INTRO_LABEL"
description="JGLOBAL_SHOW_INTRO_DESC"
useglobal="true"
class="chzn-color"
>
<option value="1">JSHOW</option>
<option value="0">JHIDE</option>
</field>
<field
name="info_block_position"
type="list"
label="COM_CONTENT_FIELD_INFOBLOCK_POSITION_LABEL"
description="COM_CONTENT_FIELD_INFOBLOCK_POSITION_DESC"
useglobal="true"
>
<option value="0">COM_CONTENT_FIELD_OPTION_ABOVE</option>
<option value="1">COM_CONTENT_FIELD_OPTION_BELOW</option>
<option value="2">COM_CONTENT_FIELD_OPTION_SPLIT</option>
</field>
<field
name="info_block_show_title"
type="list"
label="COM_CONTENT_FIELD_INFOBLOCK_TITLE_LABEL"
description="COM_CONTENT_FIELD_INFOBLOCK_TITLE_DESC"
useglobal="true"
class="chzn-color"
>
<option value="1">JSHOW</option>
<option value="0">JHIDE</option>
</field>
<field
name="show_category"
type="list"
label="JGLOBAL_SHOW_CATEGORY_LABEL"
description="JGLOBAL_SHOW_CATEGORY_DESC"
useglobal="true"
class="chzn-color"
>
<option value="1">JSHOW</option>
<option value="0">JHIDE</option>
</field>
<field
name="link_category"
type="list"
label="JGLOBAL_LINK_CATEGORY_LABEL"
description="JGLOBAL_LINK_CATEGORY_DESC"
useglobal="true"
class="chzn-color"
>
<option value="1">JYES</option>
<option value="0">JNO</option>
</field>
<field
name="show_parent_category"
type="list"
label="JGLOBAL_SHOW_PARENT_CATEGORY_LABEL"
description="JGLOBAL_SHOW_PARENT_CATEGORY_DESC"
useglobal="true"
class="chzn-color"
>
<option value="1">JSHOW</option>
<option value="0">JHIDE</option>
</field>
<field
name="link_parent_category"
type="list"
label="JGLOBAL_LINK_PARENT_CATEGORY_LABEL"
description="JGLOBAL_LINK_PARENT_CATEGORY_DESC"
useglobal="true"
class="chzn-color"
>
<option value="1">JYES</option>
<option value="0">JNO</option>
</field>
<field
name="show_associations"
type="list"
label="JGLOBAL_SHOW_ASSOCIATIONS_LABEL"
description="JGLOBAL_SHOW_ASSOCIATIONS_DESC"
useglobal="true"
class="chzn-color"
>
<option value="1">JSHOW</option>
<option value="0">JHIDE</option>
</field>
<field
name="show_author"
type="list"
label="JGLOBAL_SHOW_AUTHOR_LABEL"
description="JGLOBAL_SHOW_AUTHOR_DESC"
useglobal="true"
class="chzn-color"
>
<option value="1">JSHOW</option>
<option value="0">JHIDE</option>
</field>
<field
name="link_author"
type="list"
label="JGLOBAL_LINK_AUTHOR_LABEL"
description="JGLOBAL_LINK_AUTHOR_DESC"
useglobal="true"
class="chzn-color"
>
<option value="1">JYES</option>
<option value="0">JNO</option>
</field>
<field
name="show_create_date"
type="list"
label="JGLOBAL_SHOW_CREATE_DATE_LABEL"
description="JGLOBAL_SHOW_CREATE_DATE_DESC"
useglobal="true"
class="chzn-color"
>
<option value="1">JSHOW</option>
<option value="0">JHIDE</option>
</field>
<field
name="show_modify_date"
type="list"
label="JGLOBAL_SHOW_MODIFY_DATE_LABEL"
description="JGLOBAL_SHOW_MODIFY_DATE_DESC"
useglobal="true"
class="chzn-color"
>
<option value="1">JSHOW</option>
<option value="0">JHIDE</option>
</field>
<field
name="show_publish_date"
type="list"
label="JGLOBAL_SHOW_PUBLISH_DATE_LABEL"
description="JGLOBAL_SHOW_PUBLISH_DATE_DESC"
useglobal="true"
class="chzn-color"
>
<option value="1">JSHOW</option>
<option value="0">JHIDE</option>
</field>
<field
name="show_item_navigation"
type="list"
label="JGLOBAL_SHOW_NAVIGATION_LABEL"
description="JGLOBAL_SHOW_NAVIGATION_DESC"
useglobal="true"
class="chzn-color"
>
<option value="1">JSHOW</option>
<option value="0">JHIDE</option>
</field>
<field
name="show_vote"
type="list"
label="JGLOBAL_SHOW_VOTE_LABEL"
description="JGLOBAL_SHOW_VOTE_DESC"
useglobal="true"
class="chzn-color"
>
<option value="1">JSHOW</option>
<option value="0">JHIDE</option>
</field>
<field
name="show_icons"
type="list"
label="JGLOBAL_SHOW_ICONS_LABEL"
description="JGLOBAL_SHOW_ICONS_DESC"
useglobal="true"
class="chzn-color"
>
<option value="1">JSHOW</option>
<option value="0">JHIDE</option>
</field>
<field
name="show_print_icon"
type="list"
label="JGLOBAL_SHOW_PRINT_ICON_LABEL"
description="JGLOBAL_SHOW_PRINT_ICON_DESC"
useglobal="true"
class="chzn-color"
>
<option value="1">JSHOW</option>
<option value="0">JHIDE</option>
</field>
<field
name="show_email_icon"
type="list"
label="JGLOBAL_SHOW_EMAIL_ICON_LABEL"
description="JGLOBAL_SHOW_EMAIL_ICON_DESC"
useglobal="true"
class="chzn-color"
>
<option value="1">JSHOW</option>
<option value="0">JHIDE</option>
</field>
<field
name="show_hits"
type="list"
label="JGLOBAL_SHOW_HITS_LABEL"
description="JGLOBAL_SHOW_HITS_DESC"
useglobal="true"
class="chzn-color"
>
<option value="1">JSHOW</option>
<option value="0">JHIDE</option>
</field>
<field
name="show_tags"
type="list"
label="JGLOBAL_SHOW_TAGS_LABEL"
description="JGLOBAL_SHOW_TAGS_DESC"
useglobal="true"
class="chzn-color"
>
<option value="1">JSHOW</option>
<option value="0">JHIDE</option>
</field>
<field
name="show_noauth"
type="list"
label="JGLOBAL_SHOW_UNAUTH_LINKS_LABEL"
description="JGLOBAL_SHOW_UNAUTH_LINKS_DESC"
useglobal="true"
class="chzn-color"
>
<option value="1">JYES</option>
<option value="0">JNO</option>
</field>
<field
name="urls_position"
type="list"
label="COM_CONTENT_FIELD_URLSPOSITION_LABEL"
description="COM_CONTENT_FIELD_URLSPOSITION_DESC"
useglobal="true"
>
<option value="0">COM_CONTENT_FIELD_OPTION_ABOVE</option>
<option value="1">COM_CONTENT_FIELD_OPTION_BELOW</option>
</field>
</fieldset>
</fields>
</metadata>
tmpl/default.php 0000604 00000016200 15245536013 0007654 0 ustar 00 <?php
/**
* @package Joomla.Site
* @subpackage com_content
*
* @copyright (C) 2006 Open Source Matters, Inc. <https://www.joomla.org>
* @license GNU General Public License version 2 or later; see LICENSE.txt
*/
defined('_JEXEC') or die;
JHtml::addIncludePath(JPATH_COMPONENT . '/helpers');
// Create shortcuts to some parameters.
$params = $this->item->params;
$urls = json_decode($this->item->urls);
$canEdit = $params->get('access-edit');
$user = JFactory::getUser();
$info = $params->get('info_block_position', 0);
// Check if associations are implemented. If they are, define the parameter.
$assocParam = (JLanguageAssociations::isEnabled() && $params->get('show_associations'));
JHtml::_('behavior.caption');
$currentDate = JFactory::getDate()->format('Y-m-d H:i:s');
$isNotPublishedYet = $this->item->publish_up > $currentDate;
$isExpired = $this->item->publish_down < $currentDate && $this->item->publish_down !== JFactory::getDbo()->getNullDate();
?>
<div class="item-page<?php echo $this->pageclass_sfx; ?>" itemscope itemtype="https://schema.org/Article">
<meta itemprop="inLanguage" content="<?php echo ($this->item->language === '*') ? JFactory::getConfig()->get('language') : $this->item->language; ?>" />
<?php if ($this->params->get('show_page_heading')) : ?>
<div class="page-header">
<h1> <?php echo $this->escape($this->params->get('page_heading')); ?> </h1>
</div>
<?php endif;
if (!empty($this->item->pagination) && $this->item->pagination && !$this->item->paginationposition && $this->item->paginationrelative)
{
echo $this->item->pagination;
}
?>
<?php // Todo Not that elegant would be nice to group the params ?>
<?php $useDefList = ($params->get('show_modify_date') || $params->get('show_publish_date') || $params->get('show_create_date')
|| $params->get('show_hits') || $params->get('show_category') || $params->get('show_parent_category') || $params->get('show_author') || $assocParam); ?>
<?php if (!$useDefList && $this->print) : ?>
<div id="pop-print" class="btn hidden-print">
<?php echo JHtml::_('icon.print_screen', $this->item, $params); ?>
</div>
<div class="clearfix"> </div>
<?php endif; ?>
<?php if ($params->get('show_title')) : ?>
<div class="page-header">
<h2 itemprop="headline">
<?php echo $this->escape($this->item->title); ?>
</h2>
<?php if ($this->item->state == 0) : ?>
<span class="label label-warning"><?php echo JText::_('JUNPUBLISHED'); ?></span>
<?php endif; ?>
<?php if ($isNotPublishedYet) : ?>
<span class="label label-warning"><?php echo JText::_('JNOTPUBLISHEDYET'); ?></span>
<?php endif; ?>
<?php if ($isExpired) : ?>
<span class="label label-warning"><?php echo JText::_('JEXPIRED'); ?></span>
<?php endif; ?>
</div>
<?php endif; ?>
<?php if (!$this->print) : ?>
<?php if ($canEdit || $params->get('show_print_icon') || $params->get('show_email_icon')) : ?>
<?php echo JLayoutHelper::render('joomla.content.icons', array('params' => $params, 'item' => $this->item, 'print' => false)); ?>
<?php endif; ?>
<?php else : ?>
<?php if ($useDefList) : ?>
<div id="pop-print" class="btn hidden-print">
<?php echo JHtml::_('icon.print_screen', $this->item, $params); ?>
</div>
<?php endif; ?>
<?php endif; ?>
<?php // Content is generated by content plugin event "onContentAfterTitle" ?>
<?php echo $this->item->event->afterDisplayTitle; ?>
<?php if ($useDefList && ($info == 0 || $info == 2)) : ?>
<?php // Todo: for Joomla4 joomla.content.info_block.block can be changed to joomla.content.info_block ?>
<?php echo JLayoutHelper::render('joomla.content.info_block.block', array('item' => $this->item, 'params' => $params, 'position' => 'above')); ?>
<?php endif; ?>
<?php if ($info == 0 && $params->get('show_tags', 1) && !empty($this->item->tags->itemTags)) : ?>
<?php $this->item->tagLayout = new JLayoutFile('joomla.content.tags'); ?>
<?php echo $this->item->tagLayout->render($this->item->tags->itemTags); ?>
<?php endif; ?>
<?php // Content is generated by content plugin event "onContentBeforeDisplay" ?>
<?php echo $this->item->event->beforeDisplayContent; ?>
<?php if (isset($urls) && ((!empty($urls->urls_position) && ($urls->urls_position == '0')) || ($params->get('urls_position') == '0' && empty($urls->urls_position)))
|| (empty($urls->urls_position) && (!$params->get('urls_position')))) : ?>
<?php echo $this->loadTemplate('links'); ?>
<?php endif; ?>
<?php if ($params->get('access-view')) : ?>
<?php echo JLayoutHelper::render('joomla.content.full_image', $this->item); ?>
<?php
if (!empty($this->item->pagination) && $this->item->pagination && !$this->item->paginationposition && !$this->item->paginationrelative) :
echo $this->item->pagination;
endif;
?>
<?php if (isset ($this->item->toc)) :
echo $this->item->toc;
endif; ?>
<div itemprop="articleBody">
<?php echo $this->item->text; ?>
</div>
<?php if ($info == 1 || $info == 2) : ?>
<?php if ($useDefList) : ?>
<?php // Todo: for Joomla4 joomla.content.info_block.block can be changed to joomla.content.info_block ?>
<?php echo JLayoutHelper::render('joomla.content.info_block.block', array('item' => $this->item, 'params' => $params, 'position' => 'below')); ?>
<?php endif; ?>
<?php if ($params->get('show_tags', 1) && !empty($this->item->tags->itemTags)) : ?>
<?php $this->item->tagLayout = new JLayoutFile('joomla.content.tags'); ?>
<?php echo $this->item->tagLayout->render($this->item->tags->itemTags); ?>
<?php endif; ?>
<?php endif; ?>
<?php
if (!empty($this->item->pagination) && $this->item->pagination && $this->item->paginationposition && !$this->item->paginationrelative) :
echo $this->item->pagination;
?>
<?php endif; ?>
<?php if (isset($urls) && ((!empty($urls->urls_position) && ($urls->urls_position == '1')) || ($params->get('urls_position') == '1'))) : ?>
<?php echo $this->loadTemplate('links'); ?>
<?php endif; ?>
<?php // Optional teaser intro text for guests ?>
<?php elseif ($params->get('show_noauth') == true && $user->get('guest')) : ?>
<?php echo JLayoutHelper::render('joomla.content.intro_image', $this->item); ?>
<?php echo JHtml::_('content.prepare', $this->item->introtext); ?>
<?php // Optional link to let them register to see the whole article. ?>
<?php if ($params->get('show_readmore') && $this->item->fulltext != null) : ?>
<?php $menu = JFactory::getApplication()->getMenu(); ?>
<?php $active = $menu->getActive(); ?>
<?php $itemId = $active->id; ?>
<?php $link = new JUri(JRoute::_('index.php?option=com_users&view=login&Itemid=' . $itemId, false)); ?>
<?php $link->setVar('return', base64_encode(ContentHelperRoute::getArticleRoute($this->item->slug, $this->item->catid, $this->item->language))); ?>
<?php echo JLayoutHelper::render('joomla.content.readmore', array('item' => $this->item, 'params' => $params, 'link' => $link)); ?>
<?php endif; ?>
<?php endif; ?>
<?php
if (!empty($this->item->pagination) && $this->item->pagination && $this->item->paginationposition && $this->item->paginationrelative) :
echo $this->item->pagination;
?>
<?php endif; ?>
<?php // Content is generated by content plugin event "onContentAfterDisplay" ?>
<?php echo $this->item->event->afterDisplayContent; ?>
</div>
tmpl/default_links.php 0000604 00000005000 15245536013 0011050 0 ustar 00 <?php
/**
* @package Joomla.Site
* @subpackage com_content
*
* @copyright (C) 2011 Open Source Matters, Inc. <https://www.joomla.org>
* @license GNU General Public License version 2 or later; see LICENSE.txt
*/
defined('_JEXEC') or die;
// Create shortcut
$urls = json_decode($this->item->urls);
// Create shortcuts to some parameters.
$params = $this->item->params;
if ($urls && (!empty($urls->urla) || !empty($urls->urlb) || !empty($urls->urlc))) :
?>
<div class="content-links">
<ul class="nav nav-tabs nav-stacked">
<?php
$urlarray = array(
array($urls->urla, $urls->urlatext, $urls->targeta, 'a'),
array($urls->urlb, $urls->urlbtext, $urls->targetb, 'b'),
array($urls->urlc, $urls->urlctext, $urls->targetc, 'c')
);
foreach ($urlarray as $url) :
$link = $url[0];
$label = $url[1];
$target = $url[2];
$id = $url[3];
if ( ! $link) :
continue;
endif;
// If no label is present, take the link
$label = $label ?: $link;
// If no target is present, use the default
$target = $target ?: $params->get('target' . $id);
?>
<li class="content-links-<?php echo $id; ?>">
<?php
// Compute the correct link
switch ($target)
{
case 1:
// Open in a new window
echo '<a href="' . htmlspecialchars($link, ENT_COMPAT, 'UTF-8') . '" target="_blank" rel="nofollow noopener noreferrer">' .
htmlspecialchars($label, ENT_COMPAT, 'UTF-8') . '</a>';
break;
case 2:
// Open in a popup window
$attribs = 'toolbar=no,location=no,status=no,menubar=no,scrollbars=yes,resizable=yes,width=600,height=600';
echo "<a href=\"" . htmlspecialchars($link, ENT_COMPAT, 'UTF-8') . "\" onclick=\"window.open(this.href, 'targetWindow', '" . $attribs . "'); return false;\" rel=\"noopener noreferrer\">" .
htmlspecialchars($label, ENT_COMPAT, 'UTF-8') . '</a>';
break;
case 3:
// Open in a modal window
JHtml::_('behavior.modal', 'a.modal');
echo '<a class="modal" href="' . htmlspecialchars($link, ENT_COMPAT, 'UTF-8') . '" rel="{handler: \'iframe\', size: {x:600, y:600}} noopener noreferrer">' .
htmlspecialchars($label, ENT_COMPAT, 'UTF-8') . ' </a>';
break;
default:
// Open in parent window
echo '<a href="' . htmlspecialchars($link, ENT_COMPAT, 'UTF-8') . '" rel="nofollow">' .
htmlspecialchars($label, ENT_COMPAT, 'UTF-8') . ' </a>';
break;
}
?>
</li>
<?php endforeach; ?>
</ul>
</div>
<?php endif; ?>
article.php 0000604 00000003517 15245572046 0006714 0 ustar 00 <?php
/**
* @package Joomla.Plugin
* @subpackage Editors-xtd.article
*
* @copyright (C) 2009 Open Source Matters, Inc. <https://www.joomla.org>
* @license GNU General Public License version 2 or later; see LICENSE.txt
*/
defined('_JEXEC') or die;
/**
* Editor Article button
*
* @since 1.5
*/
class PlgButtonArticle extends JPlugin
{
/**
* Load the language file on instantiation.
*
* @var boolean
* @since 3.1
*/
protected $autoloadLanguage = true;
/**
* Display the button
*
* @param string $name The name of the button to add
*
* @return JObject The button options as JObject
*
* @since 1.5
*/
public function onDisplay($name)
{
$input = JFactory::getApplication()->input;
$user = JFactory::getUser();
// Can create in any category (component permission) or at least in one category
$canCreateRecords = $user->authorise('core.create', 'com_content')
|| count($user->getAuthorisedCategories('com_content', 'core.create')) > 0;
// Instead of checking edit on all records, we can use **same** check as the form editing view
$values = (array) JFactory::getApplication()->getUserState('com_content.edit.article.id');
$isEditingRecords = count($values);
// This ACL check is probably a double-check (form view already performed checks)
$hasAccess = $canCreateRecords || $isEditingRecords;
if (!$hasAccess)
{
return;
}
$link = 'index.php?option=com_content&view=articles&layout=modal&tmpl=component&'
. JSession::getFormToken() . '=1&editor=' . $name;
$button = new JObject;
$button->modal = true;
$button->class = 'btn';
$button->link = $link;
$button->text = JText::_('PLG_ARTICLE_BUTTON_ARTICLE');
$button->name = 'file-add';
$button->options = "{handler: 'iframe', size: {x: 800, y: 500}}";
return $button;
}
}
article.xml 0000604 00000001430 15245572046 0006715 0 ustar 00 <?xml version="1.0" encoding="utf-8"?>
<extension version="3.1" type="plugin" group="editors-xtd" method="upgrade">
<name>plg_editors-xtd_article</name>
<author>Joomla! Project</author>
<creationDate>October 2009</creationDate>
<copyright>(C) 2009 Open Source Matters, Inc.</copyright>
<license>GNU General Public License version 2 or later; see LICENSE.txt</license>
<authorEmail>admin@joomla.org</authorEmail>
<authorUrl>www.joomla.org</authorUrl>
<version>3.0.0</version>
<description>PLG_ARTICLE_XML_DESCRIPTION</description>
<files>
<filename plugin="article">article.php</filename>
</files>
<languages>
<language tag="en-GB">en-GB.plg_editors-xtd_article.ini</language>
<language tag="en-GB">en-GB.plg_editors-xtd_article.sys.ini</language>
</languages>
</extension>
default.php 0000604 00000020627 15245613457 0006720 0 ustar 00 <?php
/**
* @package Joomla.Site
* @subpackage com_content
*
* @copyright Copyright (C) 2005 - 2021 Open Source Matters, Inc. All rights reserved.
* @license GNU General Public License version 2 or later; see LICENSE.txt
*/
defined('_JEXEC') or die;
use Joomla\CMS\Uri\Uri;
use Joomla\CMS\Factory;
use Joomla\CMS\HTML\HTMLHelper;
use Joomla\CMS\Language\Associations;
use Joomla\CMS\Language\Text;
use Joomla\CMS\Layout\FileLayout;
use Joomla\CMS\Layout\LayoutHelper;
use Joomla\CMS\Router\Route;
if(!class_exists('ContentHelperRoute')){
if(version_compare(JVERSION, '4', 'ge')){
abstract class ContentHelperRoute extends \Joomla\Component\content\Site\Helper\RouteHelper{};
}else{
JLoader::register('ContentHelperRoute', $com_path . '/helpers/route.php');
}
}
HTMLHelper::addIncludePath(JPATH_COMPONENT . '/helpers');
// T3 ovrride
HTMLHelper::addIncludePath(T3_PATH . '/html/com_content');
HTMLHelper::addIncludePath(dirname(dirname(__FILE__)));
// Create shortcuts to some parameters.
$params = $this->item->params;
$images = json_decode($this->item->images);
$urls = json_decode($this->item->urls);
$canEdit = $params->get('access-edit');
$user = Factory::getUser();
$info = $params->get('info_block_position', 0);
// T3 ovrride.
$aInfo1 = ($params->get('show_publish_date') || $params->get('show_category') || $params->get('show_parent_category') || $params->get('show_author'));
$aInfo2 = ($params->get('show_create_date') || $params->get('show_modify_date') || $params->get('show_hits'));
$topInfo = ($aInfo1 && $info != 1) || ($aInfo2 && $info == 0);
$botInfo = ($aInfo1 && $info == 1) || ($aInfo2 && $info != 0);
$icons = !empty($this->print) || $canEdit || $params->get('show_print_icon') || $params->get('show_email_icon');
// Check if associations are implemented. If they are, define the parameter.
$assocParam = (Associations::isEnabled() && $params->get('show_associations'));
if(version_compare(JVERSION, '4', 'lt')){
HTMLHelper::_('behavior.caption');
}
?>
<!-- Page header -->
<?php if ($this->params->get('show_page_heading')) : ?>
<div class="page-header">
<h1> <?php echo $this->escape($this->params->get('page_heading')); ?> </h1>
</div>
<?php endif; ?>
<!-- // Page header -->
<div class="item-page<?php echo $this->pageclass_sfx; ?>" itemscope itemtype="https://schema.org/Article">
<?php if (!empty($this->item->pagination) && $this->item->pagination && !$this->item->paginationposition && $this->item->paginationrelative) {
echo $this->item->pagination;
} ?>
<!-- Article -->
<article itemscope itemtype="http://schema.org/Article">
<meta itemscope itemprop="mainEntityOfPage" itemType="https://schema.org/WebPage" itemid="https://google.com/article"/>
<meta itemprop="inLanguage" content="<?php echo ($this->item->language === '*') ? Factory::getConfig()->get('language') : $this->item->language; ?>" />
<?php if ($params->get('show_title')) : ?>
<?php echo LayoutHelper::render('joomla.content.item_title', array('item' => $this->item, 'params' => $params, 'title-tag'=>'h1')); ?>
<?php endif; ?>
<?php // Content is generated by content plugin event "onContentAfterTitle" ?>
<?php echo $this->item->event->afterDisplayTitle; ?>
<?php $useDefList = ($params->get('show_modify_date') || $params->get('show_publish_date') || $params->get('show_create_date')
|| $params->get('show_hits') || $params->get('show_category') || $params->get('show_parent_category') || $params->get('show_author') || $assocParam || $icons); ?>
<!-- Aside -->
<?php if ($useDefList && ($info == 0 || $info == 2)) : ?>
<aside class="article-aside clearfix">
<?php if ($icons): ?>
<?php echo LayoutHelper::render('joomla.content.icons', array('item' => $this->item, 'params' => $params, 'print' => $this->print)); ?>
<?php endif; ?>
<?php // Todo: for Joomla4 joomla.content.info_block.block can be changed to joomla.content.info_block ?>
<?php echo LayoutHelper::render('joomla.content.info_block.block', array('item' => $this->item, 'params' => $params, 'position' => 'above')); ?>
</aside>
<?php endif; ?>
<!-- // Aside -->
<?php if (isset ($this->item->toc)) :
echo $this->item->toc;
endif; ?>
<!-- Item tags -->
<?php if ($info == 0 && $params->get('show_tags', 1) && !empty($this->item->tags)) : ?>
<?php echo LayoutHelper::render('joomla.content.tags', $this->item->tags->itemTags); ?>
<?php endif; ?>
<!-- // Item tags -->
<?php // Content is generated by content plugin event "onContentBeforeDisplay" ?>
<?php echo $this->item->event->beforeDisplayContent; ?>
<?php if (isset($urls) && ((!empty($urls->urls_position) && ($urls->urls_position == '0')) || ($params->get('urls_position') == '0' && empty($urls->urls_position)))
|| (empty($urls->urls_position) && (!$params->get('urls_position')))) : ?>
<?php echo $this->loadTemplate('links'); ?>
<?php endif; ?>
<?php if ($params->get('access-view')) : ?>
<?php echo LayoutHelper::render('joomla.content.full_image', $this->item); ?>
<?php if (!empty($this->item->pagination) && $this->item->pagination && !$this->item->paginationposition && !$this->item->paginationrelative) :
echo $this->item->pagination;
endif; ?>
<section class="article-content clearfix" itemprop="articleBody">
<?php echo $this->item->text; ?>
</section>
<!-- Footer -->
<?php if ($useDefList && ($info == 1 || $info == 2)) : ?>
<footer class="article-footer clearfix">
<?php if ($icons && $info == 1): ?>
<?php echo LayoutHelper::render('joomla.content.icons', array('item' => $this->item, 'params' => $params, 'print' => $this->print)); ?>
<?php endif; ?>
<?php // Todo: for Joomla4 joomla.content.info_block.block can be changed to joomla.content.info_block ?>
<?php echo LayoutHelper::render('joomla.content.info_block.block', array('item' => $this->item, 'params' => $params, 'position' => 'below')); ?>
</footer>
<?php endif; ?>
<!-- // Footer -->
<?php if (!empty($this->item->pagination) && $this->item->pagination && $this->item->paginationposition && !$this->item->paginationrelative) :
echo '<hr class="divider-vertical" />';
echo $this->item->pagination; ?>
<?php endif; ?>
<?php if (isset($urls) && ((!empty($urls->urls_position) && ($urls->urls_position == '1')) || ($params->get('urls_position') == '1'))) : ?>
<?php echo $this->loadTemplate('links'); ?>
<?php endif; ?>
<?php // Optional teaser intro text for guests ?>
<?php elseif ($params->get('show_noauth') == true && $user->get('guest')) : ?>
<?php echo LayoutHelper::render('joomla.content.intro_image', $this->item); ?>
<?php echo HTMLHelper::_('content.prepare', $this->item->introtext); ?>
<?php // Optional link to let them register to see the whole article. ?>
<?php if ($params->get('show_readmore') && $this->item->fulltext != null) : ?>
<?php $menu = Factory::getApplication()->getMenu(); ?>
<?php $active = $menu->getActive(); ?>
<?php $itemId = $active->id; ?>
<?php $link = new Uri(Route::_('index.php?option=com_users&view=login&Itemid=' . $itemId, false)); ?>
<?php $link->setVar('return', base64_encode(ContentHelperRoute::getArticleRoute($this->item->slug, $this->item->catid, $this->item->language))); ?>
<section class="readmore">
<a href="<?php echo $link; ?>" class="register"><span>
<?php $attribs = json_decode($this->item->attribs); ?>
<?php
if ($attribs->alternative_readmore == null) :
echo Text::_('COM_CONTENT_REGISTER_TO_READ_MORE');
elseif ($readmore = $attribs->alternative_readmore) :
echo $readmore;
if ($params->get('show_readmore_title', 0) != 0) :
echo HTMLHelper::_('string.truncate', $this->item->title, $params->get('readmore_limit'));
endif;
elseif ($params->get('show_readmore_title', 0) == 0) :
echo Text::sprintf('COM_CONTENT_READ_MORE_TITLE');
else :
echo Text::_('COM_CONTENT_READ_MORE');
echo HTMLHelper::_('string.truncate', $this->item->title, $params->get('readmore_limit'));
endif; ?>
</span></a>
</section>
<?php endif; ?>
<?php endif; ?>
</article>
<!-- //Article -->
<?php if (!empty($this->item->pagination) && $this->item->pagination && $this->item->paginationposition && $this->item->paginationrelative) :
echo $this->item->pagination; ?>
<?php endif; ?>
<?php // Content is generated by content plugin event "onContentAfterDisplay" ?>
<?php echo $this->item->event->afterDisplayContent; ?>
</div>
default_links.php 0000604 00000005035 15245613457 0010114 0 ustar 00 <?php
/**
* @package Joomla.Site
* @subpackage com_content
*
* @copyright Copyright (C) 2005 - 2021 Open Source Matters, Inc. All rights reserved.
* @license GNU General Public License version 2 or later; see LICENSE.txt
*/
defined('_JEXEC') or die;
use Joomla\CMS\HTML\HTMLHelper;
// Create shortcut
$urls = json_decode($this->item->urls);
// Create shortcuts to some parameters.
$params = $this->item->params;
if ($urls && (!empty($urls->urla) || !empty($urls->urlb) || !empty($urls->urlc))) :
?>
<div class="content-links">
<ol class="nav">
<?php
$urlarray = array(
array($urls->urla, $urls->urlatext, $urls->targeta, 'a'),
array($urls->urlb, $urls->urlbtext, $urls->targetb, 'b'),
array($urls->urlc, $urls->urlctext, $urls->targetc, 'c')
);
foreach ($urlarray as $url) :
$link = $url[0];
$label = $url[1];
$target = $url[2];
$id = $url[3];
if ( ! $link) :
continue;
endif;
// If no label is present, take the link
$label = $label ?: $link;
// If no target is present, use the default
$target = $target ?: $params->get('target' . $id);
?>
<li class="content-links-<?php echo $id; ?>">
<?php
// Compute the correct link
switch ($target)
{
case 1:
// Open in a new window
echo '<a href="' . htmlspecialchars($link, ENT_COMPAT, 'UTF-8') . '" target="_blank" rel="nofollow noopener noreferrer">' .
htmlspecialchars($label, ENT_COMPAT, 'UTF-8') . '</a>';
break;
case 2:
// Open in a popup window
$attribs = 'toolbar=no,location=no,status=no,menubar=no,scrollbars=yes,resizable=yes,width=600,height=600';
echo "<a href=\"" . htmlspecialchars($link, ENT_COMPAT, 'UTF-8') . "\" onclick=\"window.open(this.href, 'targetWindow', '" . $attribs . "'); return false;\" rel=\"noopener noreferrer\">" .
htmlspecialchars($label, ENT_COMPAT, 'UTF-8') . '</a>';
break;
case 3:
// Open in a modal window
HTMLHelper::_('behavior.modal', 'a.modal');
echo '<a class="modal" href="' . htmlspecialchars($link, ENT_COMPAT, 'UTF-8') . '" rel="{handler: \'iframe\', size: {x:600, y:600}} noopener noreferrer">' .
htmlspecialchars($label, ENT_COMPAT, 'UTF-8') . ' </a>';
break;
default:
// Open in parent window
echo '<a href="' . htmlspecialchars($link, ENT_COMPAT, 'UTF-8') . '" rel="nofollow">' .
htmlspecialchars($label, ENT_COMPAT, 'UTF-8') . ' </a>';
break;
}
?>
</li>
<?php endforeach; ?>
</ol>
</div>
<?php endif; ?>
index.html 0000604 00000000037 15245613457 0006551 0 ustar 00 <!DOCTYPE html><title></title>
config.php 0000604 00000001224 15245630464 0006526 0 ustar 00 <?php
/**
* @package JCE
* @subpackage Editor
*
* @copyright Copyright (c) 2009-2024 Ryan Demmer. All rights reserved
* @license GNU General Public License version 2 or later; see LICENSE.txt
*/
\defined('_JEXEC') or die;
class WFArticlePluginConfig
{
public static function getConfig(&$settings)
{
$wf = WFApplication::getInstance();
//$settings['article_hide_xtd_btns'] = $wf->getParam('article.hide_xtd_btns', 0, 0);
$settings['article_show_readmore'] = $wf->getParam('article.show_readmore', 1, 1);
$settings['article_show_pagebreak'] = $wf->getParam('article.show_pagebreak', 1, 1);
}
}
tmpl/edit.xml 0000604 00000000530 15245723362 0007172 0 ustar 00 <?xml version="1.0" encoding="utf-8"?>
<metadata>
<layout title="COM_CONTENT_ARTICLE_VIEW_EDIT_TITLE">
<message>
<![CDATA[COM_CONTENT_ARTICLE_VIEW_EDIT_DESC]]>
</message>
</layout>
<fieldset name="request">
<fields name="request">
<field
name="id"
type="hidden"
default="0"
/>
</fields>
</fieldset>
</metadata>
tmpl/edit.php 0000604 00000013063 15245723362 0007166 0 ustar 00 <?php
/**
* @package Joomla.Administrator
* @subpackage com_content
*
* @copyright (C) 2009 Open Source Matters, Inc. <https://www.joomla.org>
* @license GNU General Public License version 2 or later; see LICENSE.txt
*/
defined('_JEXEC') or die;
use Joomla\Registry\Registry;
// Include the component HTML helpers.
JHtml::addIncludePath(JPATH_COMPONENT . '/helpers/html');
JHtml::_('behavior.formvalidator');
JHtml::_('behavior.keepalive');
JHtml::_('formbehavior.chosen', '#jform_catid', null, array('disable_search_threshold' => 0 ));
JHtml::_('formbehavior.chosen', '#jform_tags', null, array('placeholder_text_multiple' => JText::_('JGLOBAL_TYPE_OR_SELECT_SOME_TAGS')));
JHtml::_('formbehavior.chosen', 'select');
$this->configFieldsets = array('editorConfig');
$this->hiddenFieldsets = array('basic-limited');
$this->ignore_fieldsets = array('jmetadata', 'item_associations');
// Create shortcut to parameters.
$params = clone $this->state->get('params');
$params->merge(new Registry($this->item->attribs));
$app = JFactory::getApplication();
$input = $app->input;
$assoc = JLanguageAssociations::isEnabled();
JFactory::getDocument()->addScriptDeclaration('
Joomla.submitbutton = function(task)
{
if (task == "article.cancel" || document.formvalidator.isValid(document.getElementById("item-form")))
{
jQuery("#permissions-sliders select").attr("disabled", "disabled");
' . $this->form->getField('articletext')->save() . '
Joomla.submitform(task, document.getElementById("item-form"));
// @deprecated 4.0 The following js is not needed since 3.7.0.
if (task !== "article.apply")
{
window.parent.jQuery("#articleEdit' . (int) $this->item->id . 'Modal").modal("hide");
}
}
};
');
// In case of modal
$isModal = $input->get('layout') == 'modal' ? true : false;
$layout = $isModal ? 'modal' : 'edit';
$tmpl = $isModal || $input->get('tmpl', '', 'cmd') === 'component' ? '&tmpl=component' : '';
?>
<form action="<?php echo JRoute::_('index.php?option=com_content&layout=' . $layout . $tmpl . '&id=' . (int) $this->item->id); ?>" method="post" name="adminForm" id="item-form" class="form-validate">
<?php echo JLayoutHelper::render('joomla.edit.title_alias', $this); ?>
<div class="form-horizontal">
<?php echo JHtml::_('bootstrap.startTabSet', 'myTab', array('active' => 'general')); ?>
<?php echo JHtml::_('bootstrap.addTab', 'myTab', 'general', JText::_('COM_CONTENT_ARTICLE_CONTENT')); ?>
<div class="row-fluid">
<div class="span9">
<fieldset class="adminform">
<?php echo $this->form->getInput('articletext'); ?>
</fieldset>
</div>
<div class="span3">
<?php echo JLayoutHelper::render('joomla.edit.global', $this); ?>
</div>
</div>
<?php echo JHtml::_('bootstrap.endTab'); ?>
<?php // Do not show the images and links options if the edit form is configured not to. ?>
<?php if ($params->get('show_urls_images_backend') == 1) : ?>
<?php echo JHtml::_('bootstrap.addTab', 'myTab', 'images', JText::_('COM_CONTENT_FIELDSET_URLS_AND_IMAGES')); ?>
<div class="row-fluid form-horizontal-desktop">
<div class="span6">
<?php echo $this->form->renderField('images'); ?>
<?php foreach ($this->form->getGroup('images') as $field) : ?>
<?php echo $field->renderField(); ?>
<?php endforeach; ?>
</div>
<div class="span6">
<?php foreach ($this->form->getGroup('urls') as $field) : ?>
<?php echo $field->renderField(); ?>
<?php endforeach; ?>
</div>
</div>
<?php echo JHtml::_('bootstrap.endTab'); ?>
<?php endif; ?>
<?php $this->show_options = $params->get('show_article_options', 1); ?>
<?php echo JLayoutHelper::render('joomla.edit.params', $this); ?>
<?php // Do not show the publishing options if the edit form is configured not to. ?>
<?php if ($params->get('show_publishing_options', 1) == 1) : ?>
<?php echo JHtml::_('bootstrap.addTab', 'myTab', 'publishing', JText::_('COM_CONTENT_FIELDSET_PUBLISHING')); ?>
<div class="row-fluid form-horizontal-desktop">
<div class="span6">
<?php echo JLayoutHelper::render('joomla.edit.publishingdata', $this); ?>
</div>
<div class="span6">
<?php echo JLayoutHelper::render('joomla.edit.metadata', $this); ?>
</div>
</div>
<?php echo JHtml::_('bootstrap.endTab'); ?>
<?php endif; ?>
<?php if ( ! $isModal && $assoc) : ?>
<?php echo JHtml::_('bootstrap.addTab', 'myTab', 'associations', JText::_('JGLOBAL_FIELDSET_ASSOCIATIONS')); ?>
<?php echo $this->loadTemplate('associations'); ?>
<?php echo JHtml::_('bootstrap.endTab'); ?>
<?php elseif ($isModal && $assoc) : ?>
<div class="hidden"><?php echo $this->loadTemplate('associations'); ?></div>
<?php endif; ?>
<?php if ($this->canDo->get('core.admin')) : ?>
<?php echo JHtml::_('bootstrap.addTab', 'myTab', 'editor', JText::_('COM_CONTENT_SLIDER_EDITOR_CONFIG')); ?>
<?php echo $this->form->renderFieldset('editorConfig'); ?>
<?php echo JHtml::_('bootstrap.endTab'); ?>
<?php endif; ?>
<?php if ($this->canDo->get('core.admin')) : ?>
<?php echo JHtml::_('bootstrap.addTab', 'myTab', 'permissions', JText::_('COM_CONTENT_FIELDSET_RULES')); ?>
<?php echo $this->form->getInput('rules'); ?>
<?php echo JHtml::_('bootstrap.endTab'); ?>
<?php endif; ?>
<?php echo JHtml::_('bootstrap.endTabSet'); ?>
<input type="hidden" name="task" value="" />
<input type="hidden" name="return" value="<?php echo $input->get('return', null, 'BASE64'); ?>" />
<input type="hidden" name="forcedLanguage" value="<?php echo $input->get('forcedLanguage', '', 'cmd'); ?>" />
<?php echo JHtml::_('form.token'); ?>
</div>
</form>
tmpl/modal.php 0000604 00000002537 15245723362 0007341 0 ustar 00 <?php
/**
* @package Joomla.Administrator
* @subpackage com_content
*
* @copyright (C) 2013 Open Source Matters, Inc. <https://www.joomla.org>
* @license GNU General Public License version 2 or later; see LICENSE.txt
*/
defined('_JEXEC') or die;
JHtml::_('bootstrap.tooltip', '.hasTooltip', array('placement' => 'bottom'));
// @deprecated 4.0 the function parameter, the inline js and the buttons are not needed since 3.7.0.
$function = JFactory::getApplication()->input->getCmd('function', 'jEditArticle_' . (int) $this->item->id);
// Function to update input title when changed
JFactory::getDocument()->addScriptDeclaration('
function jEditArticleModal() {
if (window.parent && document.formvalidator.isValid(document.getElementById("item-form"))) {
return window.parent.' . $this->escape($function) . '(document.getElementById("jform_title").value);
}
}
');
?>
<button id="applyBtn" type="button" class="hidden" onclick="Joomla.submitbutton('article.apply'); jEditArticleModal();"></button>
<button id="saveBtn" type="button" class="hidden" onclick="Joomla.submitbutton('article.save'); jEditArticleModal();"></button>
<button id="closeBtn" type="button" class="hidden" onclick="Joomla.submitbutton('article.cancel');"></button>
<div class="container-popup">
<?php $this->setLayout('edit'); ?>
<?php echo $this->loadTemplate(); ?>
</div>
tmpl/modal_metadata.php 0000604 00000000504 15245723362 0011171 0 ustar 00 <?php
/**
* @package Joomla.Administrator
* @subpackage com_content
*
* @copyright (C) 2013 Open Source Matters, Inc. <https://www.joomla.org>
* @license GNU General Public License version 2 or later; see LICENSE.txt
*/
defined('_JEXEC') or die;
echo JLayoutHelper::render('joomla.edit.metadata', $this);
tmpl/modal_associations.php 0000604 00000000510 15245723362 0012105 0 ustar 00 <?php
/**
* @package Joomla.Administrator
* @subpackage com_content
*
* @copyright (C) 2013 Open Source Matters, Inc. <https://www.joomla.org>
* @license GNU General Public License version 2 or later; see LICENSE.txt
*/
defined('_JEXEC') or die;
echo JLayoutHelper::render('joomla.edit.associations', $this);
tmpl/edit_metadata.php 0000604 00000000504 15245723362 0011022 0 ustar 00 <?php
/**
* @package Joomla.Administrator
* @subpackage com_content
*
* @copyright (C) 2010 Open Source Matters, Inc. <https://www.joomla.org>
* @license GNU General Public License version 2 or later; see LICENSE.txt
*/
defined('_JEXEC') or die;
echo JLayoutHelper::render('joomla.edit.metadata', $this);
tmpl/pagebreak.php 0000604 00000002616 15245723362 0010164 0 ustar 00 <?php
/**
* @package Joomla.Administrator
* @subpackage com_content
*
* @copyright (C) 2010 Open Source Matters, Inc. <https://www.joomla.org>
* @license GNU General Public License version 2 or later; see LICENSE.txt
*/
defined('_JEXEC') or die;
JHtml::_('behavior.core');
JHtml::_('behavior.polyfill', array('event'), 'lt IE 9');
JHtml::_('script', 'com_content/admin-article-pagebreak.min.js', array('version' => 'auto', 'relative' => true));
$document = JFactory::getDocument();
$this->eName = JFactory::getApplication()->input->getCmd('e_name', '');
$this->eName = preg_replace('#[^A-Z0-9\-\_\[\]]#i', '', $this->eName);
$document->setTitle(JText::_('COM_CONTENT_PAGEBREAK_DOC_TITLE'));
?>
<div class="container-popup">
<form class="form-horizontal">
<div class="control-group">
<label for="title" class="control-label"><?php echo JText::_('COM_CONTENT_PAGEBREAK_TITLE'); ?></label>
<div class="controls"><input type="text" id="title" name="title" /></div>
</div>
<div class="control-group">
<label for="alias" class="control-label"><?php echo JText::_('COM_CONTENT_PAGEBREAK_TOC'); ?></label>
<div class="controls"><input type="text" id="alt" name="alt" /></div>
</div>
<button onclick="insertPagebreak('<?php echo $this->eName; ?>');" class="btn btn-success pull-right">
<?php echo JText::_('COM_CONTENT_PAGEBREAK_INSERT_BUTTON'); ?>
</button>
</form>
</div>
tmpl/edit_associations.php 0000604 00000000510 15245723362 0011736 0 ustar 00 <?php
/**
* @package Joomla.Administrator
* @subpackage com_content
*
* @copyright (C) 2012 Open Source Matters, Inc. <https://www.joomla.org>
* @license GNU General Public License version 2 or later; see LICENSE.txt
*/
defined('_JEXEC') or die;
echo JLayoutHelper::render('joomla.edit.associations', $this);
plugin.js 0000604 00000022444 15246331226 0006406 0 ustar 00 /* jce - 2.9.99.2 | 2026-04-22 | https://www.joomlacontenteditor.net | Source: https://github.com/widgetfactory/jce | Copyright (C) 2006 - 2026 Ryan Demmer. All rights reserved | GNU/GPL Version 2 or later - http://www.gnu.org/licenses/gpl-2.0.html */
!function() {
var DOM = tinymce.DOM, each = tinymce.each, VK = tinymce.VK, BACKSPACE = VK.BACKSPACE, DELETE = VK.DELETE;
tinymce.PluginManager.add("article", function(ed, url) {
function isReadMore(n) {
return ed.dom.is(n, "hr.mce-item-readmore");
}
function isPageBreak(n) {
return ed.dom.is(n, "hr.mce-item-pagebreak");
}
function _cancelResize() {
each(ed.dom.select("hr.mce-item-pagebreak, hr.mce-item-readmore"), function(n) {
n.onresizestart = function() {
return !1;
}, n.onbeforeeditfocus = function() {
return !1;
};
});
}
function insertBreak(s, args) {
var h, dom = ed.dom, n = ed.selection.getNode(), blocks = "H1,H2,H3,H4,H5,H6,P,DIV,ADDRESS,PRE,FORM,TABLE,OL,UL,CAPTION,BLOCKQUOTE,CENTER,DL,DIR,FIELDSET,NOSCRIPT,NOFRAMES,MENU,ISINDEX,SAMP,SECTION,ARTICLE,HGROUP,ASIDE,FIGURE", n = dom.getParent(n, blocks, "BODY") || n, marker = (tinymce.extend(args, {
class: "pagebreak" == s ? "mce-item-pagebreak" : "mce-item-readmore",
"data-alt": args.alt || null
}), args.alt = null, "readmore" == s && (args.id = "system-readmore"),
ed.execCommand("mceInsertContent", !1, '<span id="mce_hr_marker" data-mce-type="bookmark">\ufeff</span>', {
skip_undo: 1
}), dom.get("mce_hr_marker")), args = dom.create("hr", args);
if (dom.isBlock(n)) {
var ns, p = dom.getParent(marker, blocks, "BODY");
if ("P" == p.nodeName || "DIV" == p.nodeName) -1 !== p.className.indexOf("wf-column") ? (blocks = dom.getParent(n, ".wf-columns"),
dom.insertAfter(marker, blocks)) : (dom.split(p, marker), (ns = marker.nextSibling) && ns.nodeName == p.nodeName && /^(\s| |\u00a00)*?$/.test(h) && dom.remove(ns)); else for (p ? "BODY" == p.parentNode.nodeName ? dom.insertAfter(marker, p) : p.parentNode.insertBefore(marker, p) : "BODY" == n.parentNode.nodeName ? dom.insertAfter(marker, n) : n.parentNode.insertBefore(marker, n),
p = marker.parentNode; /^(H[1-6]|ADDRESS|PRE|FORM|TABLE|OL|UL|CAPTION|BLOCKQUOTE|CENTER|DL|DIR|FIELDSET|NOSCRIPT|NOFRAMES|MENU|ISINDEX|SAMP)$/.test(p.nodeName); ) p.parentNode.insertBefore(marker, p),
p = marker.parentNode;
(ns = marker.nextSibling) || (blocks = ed.getParam("forced_root_block") || "br",
ns = ed.dom.create(blocks), "br" != blocks && (ns.innerHTML = "\xa0"),
ed.dom.insertAfter(ns, marker), s = ed.selection.select(ns), ed.selection.collapse(1));
}
ed.dom.replace(args, marker), ed.undoManager.add();
}
ed.addCommand("mceReadMore", function() {
if (ed.dom.get("system-readmore")) return alert(ed.getLang("article.readmore_alert", "There is already a Read More break inserted in this article. Only one such break is permitted. Use a Pagebreak to split the page up further.")),
!1;
insertBreak("readmore", {
id: "system-readmore"
});
}), ed.addCommand("mcePageBreak", function(ui, v) {
var n = ed.selection.getNode();
isPageBreak(n) ? function(n, v) {
tinymce.extend(v, {
"data-alt": v.alt || ""
}), v.alt = null, ed.dom.setAttribs(n, v);
}(n, v) : insertBreak("pagebreak", v);
}), ed.getParam("article_show_readmore", !0) && ed.addButton("readmore", {
title: "article.readmore",
cmd: "mceReadMore"
}), ed.onInit.add(function() {
ed.theme && ed.theme.onResolveName && ed.theme.onResolveName.add(function(theme, o) {
var v, n = o.node;
n && "HR" === n.nodeName && /mce-item-pagebreak/.test(n.className) && (v = "pagebreak"),
(v = n && "HR" === n.nodeName && /mce-item-readmore/.test(n.className) ? "readmore" : v) && (o.name = v);
});
}), ed.onNodeChange.add(function(ed, cm, n) {
cm.setActive("readmore", isReadMore(n)), cm.setActive("pagebreak", isPageBreak(n)),
ed.dom.removeClass(ed.dom.select("hr.mce-item-pagebreak.mce-item-selected, hr.mce-item-readmore.mce-item-selected"), "mce-item-selected"),
(isPageBreak(n) || isReadMore(n)) && ed.dom.addClass(n, "mce-item-selected");
}), ed.onBeforeSetContent.add(function(ed, o) {
o.content = o.content.replace(/<hr(.*?) alt="([^"]+)"([^>]*?)>/gi, '<hr$1 data-alt="$2"$3>');
}), ed.onPostProcess.add(function(ed, o) {
o.get && (o.content = o.content.replace(/<hr(.*?)data-alt="([^"]+)"([^>]*?)>/gi, '<hr$1alt="$2"$3>'));
}), ed.onSetContent.add(function() {
tinymce.isIE && _cancelResize();
}), ed.onGetContent.add(function() {
tinymce.isIE && _cancelResize();
}), ed.onKeyDown.add(function(ed, e) {
var n;
e.keyCode != BACKSPACE && e.keyCode != DELETE || (n = ed.selection.getNode(),
ed.dom.is(n, "hr.mce-item-pagebreak, hr.mce-item-readmore") && (ed.dom.remove(n),
e.preventDefault()));
}), ed.onPreInit.add(function() {
ed.onBeforeSetContent.addToTop(function(ed, o) {
o.content = o.content.replace(/<hr([^>]*)\salt="([^"]+)"([^>]*)>/gi, '<hr$1 data-alt="$2"$3>');
}), ed.parser.addNodeFilter("hr", function(nodes) {
for (var i = 0; i < nodes.length; i++) {
var node = nodes[i], id = node.attr("id") || "", cls = node.attr("class") || "";
("system-readmore" == id || /(mce-item|system)-pagebreak/.test(cls)) && (cls = /(mce-item|system)-pagebreak/.test(cls) ? "mce-item-pagebreak" : "mce-item-readmore",
node.attr("class", cls), node.attr("alt")) && (node.attr("data-alt", node.attr("alt")),
node.attr("alt", null));
}
}), ed.serializer.addNodeFilter("hr", function(nodes, name, args) {
for (var i = 0; i < nodes.length; i++) {
var node = nodes[i], cls = node.attr("class") || "";
/mce-item-(pagebreak|readmore)/.test(cls) && (/mce-item-pagebreak/.test(node.attr("class")) ? node.attr("class", "system-pagebreak") : (node.attr("class", null),
node.attr("id", "system-readmore")), node.attr("data-alt")) && (node.attr("alt", node.attr("data-alt")),
node.attr("data-alt", null));
}
});
}), ed.getParam("article_show_pagebreak", !0) && ed.addButton("pagebreak", {
title: "article.pagebreak",
onclick: function() {
var html = '<div class="mceFormRow"> <label for="' + ed.id + 'article_title">' + ed.getLang("article.title", "Title") + '</label> <div class="mceFormControl"> <input type="text" id="' + ed.id + '_article_title" autofocus /> </div></div><div class="mceFormRow"> <label for="' + ed.id + '_article_alt">' + ed.getLang("article.alias", "Alias") + '</label> <div class="mceFormControl"> <input type="text" id="' + ed.id + '_article_alt" /> </div></div>';
ed.windowManager.open({
title: ed.getLang("article.pagebreak", "PageBreak"),
content: html,
size: "mce-modal-landscape-small",
open: function() {
var label = ed.getLang("insert", "Insert"), title = DOM.get(ed.id + "_article_title"), alt = DOM.get(ed.id + "_article_alt"), o = function() {
var o, n = ed.selection.getNode();
ed.dom.is(n, "hr.mce-item-pagebreak") && (o = {
title: ed.dom.getAttrib(n, "title", ""),
alt: ed.dom.getAttrib(n, "data-alt", "")
});
return o;
}();
o && (label = ed.getLang("update", "Update"), title.value = o.title || "",
alt.value = o.alt || ""), DOM.setHTML(this.id + "_insert", label),
window.setTimeout(function() {
title.focus();
}, 10);
},
buttons: [ {
title: ed.getLang("cancel", "Cancel"),
id: "cancel"
}, {
title: ed.getLang("insert", "Insert"),
id: "insert",
onsubmit: function(e) {
var title = DOM.getValue(ed.id + "_article_title"), alt = DOM.getValue(ed.id + "_article_alt");
ed.execCommand("mcePageBreak", !1, {
title: title,
alt: alt
});
},
classes: "primary"
} ]
});
}
});
});
}(); edit.php 0000604 00000025205 15246532163 0006211 0 ustar 00 <?php
/**
* @package Joomla.Administrator
* @subpackage Template.hathor
*
* @copyright (C) 2010 Open Source Matters, Inc. <https://www.joomla.org>
* @license GNU General Public License version 2 or later; see LICENSE.txt
*/
defined('_JEXEC') or die;
// Include the component HTML helpers.
JHtml::addIncludePath(JPATH_COMPONENT.'/helpers/html');
JHtml::_('behavior.formvalidator');
JHtml::_('behavior.keepalive');
// Create shortcut to parameters.
$params = $this->state->get('params');
$params = $params->toArray();
$saveHistory = $this->state->get('params')->get('save_history', 0);
// This checks if the config options have ever been saved. If they haven't they will fall back to the original settings.
$editoroptions = isset($params['show_publishing_options']);
$input = JFactory::getApplication()->input;
if (!$editoroptions):
$params['show_publishing_options'] = '1';
$params['show_article_options'] = '1';
$params['show_urls_images_backend'] = '0';
$params['show_urls_images_frontend'] = '0';
endif;
// Check if the article uses configuration settings besides global. If so, use them.
if (!empty($this->item->attribs['show_publishing_options'])):
$params['show_publishing_options'] = $this->item->attribs['show_publishing_options'];
endif;
if (!empty($this->item->attribs['show_article_options'])):
$params['show_article_options'] = $this->item->attribs['show_article_options'];
endif;
if (!empty($this->item->attribs['show_urls_images_backend'])):
$params['show_urls_images_backend'] = $this->item->attribs['show_urls_images_backend'];
endif;
$assoc = JLanguageAssociations::isEnabled();
JFactory::getDocument()->addScriptDeclaration("
Joomla.submitbutton = function(task)
{
if (task == 'article.cancel' || document.formvalidator.isValid(document.getElementById('item-form')))
{
" . $this->form->getField('articletext')->save() . "
Joomla.submitform(task, document.getElementById('item-form'));
}
}
");
?>
<div class="article-edit">
<form action="<?php echo JRoute::_('index.php?option=com_content&layout=edit&id='.(int) $this->item->id); ?>" method="post" name="adminForm" id="item-form" class="form-validate">
<div class="col main-section">
<fieldset class="adminform">
<legend><?php echo empty($this->item->id) ? JText::_('COM_CONTENT_NEW_ARTICLE') : JText::sprintf('COM_CONTENT_EDIT_ARTICLE', $this->item->id); ?></legend>
<ul class="adminformlist">
<li><?php echo $this->form->getLabel('title'); ?>
<?php echo $this->form->getInput('title'); ?></li>
<li><?php echo $this->form->getLabel('alias'); ?>
<?php echo $this->form->getInput('alias'); ?></li>
<li><?php echo $this->form->getLabel('catid'); ?>
<?php echo $this->form->getInput('catid'); ?></li>
<li><?php echo $this->form->getLabel('state'); ?>
<?php echo $this->form->getInput('state'); ?></li>
<li><?php echo $this->form->getLabel('access'); ?>
<?php echo $this->form->getInput('access'); ?></li>
<?php if ($this->canDo->get('core.admin')) : ?>
<li><span class="faux-label"><?php echo JText::_('JGLOBAL_ACTION_PERMISSIONS_LABEL'); ?></span>
<button type="button" onclick="document.location.href='#access-rules';">
<?php echo JText::_('JGLOBAL_PERMISSIONS_ANCHOR'); ?>
</button>
</li>
<?php endif; ?>
<li><?php echo $this->form->getLabel('featured'); ?>
<?php echo $this->form->getInput('featured'); ?></li>
<li><?php echo $this->form->getLabel('language'); ?>
<?php echo $this->form->getInput('language'); ?></li>
<!-- Tag field -->
<li><?php echo $this->form->getLabel('tags'); ?>
<div class="is-tagbox">
<?php echo $this->form->getInput('tags'); ?>
</div>
</li>
<?php if ($saveHistory) : ?>
<li><?php echo $this->form->getLabel('version_note'); ?>
<?php echo $this->form->getInput('version_note'); ?></li>
<?php endif; ?>
<li><?php echo $this->form->getLabel('id'); ?>
<?php echo $this->form->getInput('id'); ?></li>
</ul>
<div class="clr"></div>
<?php echo $this->form->getLabel('articletext'); ?>
<div class="clr"></div>
<?php echo $this->form->getInput('articletext'); ?>
<div class="clr"></div>
</fieldset>
</div>
<div class="col options-section">
<?php echo JHtml::_('sliders.start', 'content-sliders-' . $this->item->id, array('useCookie' => 1)); ?>
<?php // Do not show the publishing options if the edit form is configured not to. ?>
<?php if ($params['show_publishing_options'] || ( $params['show_publishing_options'] = '' && !empty($editoroptions)) ) : ?>
<?php echo JHtml::_('sliders.panel', JText::_('COM_CONTENT_FIELDSET_PUBLISHING'), 'publishing-details'); ?>
<fieldset class="panelform">
<ul class="adminformlist">
<li><?php echo $this->form->getLabel('created_by'); ?>
<?php echo $this->form->getInput('created_by'); ?></li>
<li><?php echo $this->form->getLabel('created_by_alias'); ?>
<?php echo $this->form->getInput('created_by_alias'); ?></li>
<li><?php echo $this->form->getLabel('created'); ?>
<?php echo $this->form->getInput('created'); ?></li>
<li><?php echo $this->form->getLabel('publish_up'); ?>
<?php echo $this->form->getInput('publish_up'); ?></li>
<li><?php echo $this->form->getLabel('publish_down'); ?>
<?php echo $this->form->getInput('publish_down'); ?></li>
<?php if ($this->item->modified_by) : ?>
<li><?php echo $this->form->getLabel('modified_by'); ?>
<?php echo $this->form->getInput('modified_by'); ?></li>
<li><?php echo $this->form->getLabel('modified'); ?>
<?php echo $this->form->getInput('modified'); ?></li>
<?php endif; ?>
<?php if ($this->item->version) : ?>
<li><?php echo $this->form->getLabel('version'); ?>
<?php echo $this->form->getInput('version'); ?></li>
<?php endif; ?>
<?php if ($this->item->hits) : ?>
<li><?php echo $this->form->getLabel('hits'); ?>
<?php echo $this->form->getInput('hits'); ?></li>
<?php endif; ?>
</ul>
</fieldset>
<?php endif; ?>
<?php $fieldSets = $this->form->getFieldsets(); ?>
<?php foreach ($fieldSets as $name => $fieldSet) : ?>
<?php
// If the parameter says to show the article options or if the parameters have never been set, we will
// show the article options.
if ($params['show_article_options'] || ($params['show_article_options'] == '' && !empty($editoroptions))):
// Go through all the fieldsets except the configuration and basic-limited, which are
// handled separately below.
if ($name != 'editorConfig' && $name != 'basic-limited' && $name != 'item_associations' && $name != 'jmetadata') : ?>
<?php echo JHtml::_('sliders.panel', JText::_($fieldSet->label), $name.'-options'); ?>
<?php if (isset($fieldSet->description) && trim($fieldSet->description)) : ?>
<p class="tip"><?php echo $this->escape(JText::_($fieldSet->description));?></p>
<?php endif; ?>
<fieldset class="panelform">
<ul class="adminformlist">
<?php foreach ($this->form->getFieldset($name) as $field) : ?>
<li><?php echo $field->label; ?>
<?php echo $field->input; ?></li>
<?php endforeach; ?>
</ul>
</fieldset>
<?php endif ?>
<?php // If we are not showing the options we need to use the hidden fields so the values are not lost. ?>
<?php elseif ($name == 'basic-limited') : ?>
<?php foreach ($this->form->getFieldset('basic-limited') as $field) : ?>
<?php echo $field->input; ?>
<?php endforeach; ?>
<?php endif; ?>
<?php endforeach; ?>
<?php // Not the best place, but here for continuity with 1.5/1/6/1.7 ?>
<fieldset class="panelform">
</fieldset>
<?php
// We need to make a separate space for the configuration
// so that those fields always show to those wih permissions
if ( $this->canDo->get('core.admin') ): ?>
<?php echo JHtml::_('sliders.panel', JText::_('COM_CONTENT_SLIDER_EDITOR_CONFIG'), 'configure-sliders'); ?>
<fieldset class="panelform" >
<ul class="adminformlist">
<?php foreach ($this->form->getFieldset('editorConfig') as $field) : ?>
<li><?php echo $field->label; ?>
<?php echo $field->input; ?></li>
<?php endforeach; ?>
</ul>
</fieldset>
<?php endif ?>
<?php // The URL and images fields only show if the configuration is set to allow them. ?>
<?php // This is for legacy reasons. ?>
<?php if ($params['show_urls_images_backend']) : ?>
<?php echo JHtml::_('sliders.panel', JText::_('COM_CONTENT_FIELDSET_URLS_AND_IMAGES'), 'urls_and_images-options'); ?>
<fieldset class="panelform">
<ul class="adminformlist">
<li>
<?php echo $this->form->getLabel('images'); ?>
<?php echo $this->form->getInput('images'); ?></li>
<?php foreach ($this->form->getGroup('images') as $field) : ?>
<li>
<?php if (!$field->hidden) : ?>
<?php echo $field->label; ?>
<?php endif; ?>
<?php echo $field->input; ?>
</li>
<?php endforeach; ?>
<?php foreach ($this->form->getGroup('urls') as $field) : ?>
<li>
<?php if (!$field->hidden) : ?>
<?php echo $field->label; ?>
<?php endif; ?>
<?php echo $field->input; ?>
</li>
<?php endforeach; ?>
</ul>
</fieldset>
<?php endif; ?>
<?php echo JHtml::_('sliders.panel', JText::_('JGLOBAL_FIELDSET_METADATA_OPTIONS'), 'meta-options'); ?>
<fieldset class="panelform">
<legend class="element-invisible"><?php echo JText::_('JGLOBAL_FIELDSET_METADATA_OPTIONS'); ?></legend>
<?php echo $this->loadTemplate('metadata'); ?>
</fieldset>
<?php if ($assoc) : ?>
<?php echo JHtml::_('sliders.panel', JText::_('JGLOBAL_FIELDSET_ASSOCIATIONS'), '-options');?>
<?php echo $this->loadTemplate('associations'); ?>
<?php endif; ?>
<?php echo JHtml::_('sliders.end'); ?>
</div>
<div class="clr"></div>
<?php if ($this->canDo->get('core.admin')) : ?>
<div class="col rules-section">
<?php echo JHtml::_('sliders.start', 'permissions-sliders-' . $this->item->id, array('useCookie' => 1)); ?>
<?php echo JHtml::_('sliders.panel', JText::_('COM_CONTENT_FIELDSET_RULES'), 'access-rules'); ?>
<fieldset class="panelform">
<legend class="element-invisible"><?php echo JText::_('COM_CONTENT_FIELDSET_RULES'); ?></legend>
<?php echo $this->form->getLabel('rules'); ?>
<?php echo $this->form->getInput('rules'); ?>
</fieldset>
<?php echo JHtml::_('sliders.end'); ?>
</div>
<?php endif; ?>
<div>
<input type="hidden" name="task" value="" />
<input type="hidden" name="return" value="<?php echo $input->get('return', null, 'BASE64');?>" />
<?php echo JHtml::_('form.token'); ?>
</div>
</form>
<div class="clr"></div>
</div>