Your IP : 216.73.216.61


Current Path : /home/w/u/e/wuectly/www/03cbe/
Upload File :
Current File : /home/w/u/e/wuectly/www/03cbe/com_tags.zip

PK�|!]�‚-vvhelpers/tags.phpnu&1i�<?php
/**
 * @package     Joomla.Administrator
 * @subpackage  com_tags
 *
 * @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;

/**
 * Tags helper.
 *
 * @since       3.1
 * @deprecated  4.0
 */
class TagsHelper extends JHelperContent
{
	/**
	 * Configure the Submenu links.
	 *
	 * @param   string  $extension  The extension.
	 *
	 * @return  void
	 *
	 * @since       3.1
	 * @deprecated  4.0
	 */
	public static function addSubmenu($extension)
	{
		$parts     = explode('.', $extension);
		$component = $parts[0];

		// Avoid nonsense situation.
		if ($component == 'tags')
		{
			return;
		}

		// Try to find the component helper.
		$file = JPath::clean(JPATH_ADMINISTRATOR . '/components/com_tags/helpers/tags.php');

		if (file_exists($file))
		{
			$cName = 'TagsHelper';

			JLoader::register($cName, $file);

			if (class_exists($cName))
			{
				if (is_callable(array($cName, 'addSubmenu')))
				{
					$lang = JFactory::getLanguage();

					// Loading language file from administrator/language directory then administrator/components/<extension>/language
					$lang->load($component, JPATH_BASE, null, false, true)
					||	$lang->load($component, JPath::clean(JPATH_ADMINISTRATOR . '/components/' . $component), null, false, true);
				}
			}
		}
	}
}
PK�|!]�tx�DDcontrollers/tags.phpnu&1i�<?php
/**
 * @package     Joomla.Site
 * @subpackage  com_tags
 *
 * @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;

/**
 * The Tags List Controller
 *
 * @since  3.1
 */
class TagsControllerTags extends JControllerLegacy
{
	/**
	 * Method to search tags with AJAX
	 *
	 * @return  void
	 */
	public function searchAjax()
	{
		// Required objects
		$app = JFactory::getApplication();
		$user = JFactory::getUser();

		// Receive request data
		$filters = array(
			'like'      => trim($app->input->get('like', null, 'string')),
			'title'     => trim($app->input->get('title', null, 'string')),
			'flanguage' => $app->input->get('flanguage', null, 'word'),
			'published' => $app->input->get('published', 1, 'int'),
			'parent_id' => $app->input->get('parent_id', 0, 'int'),
			'access'    => $user->getAuthorisedViewLevels(),
		);

		if ((!$user->authorise('core.edit.state', 'com_tags')) && (!$user->authorise('core.edit', 'com_tags')))
		{
			// Filter on published for those who do not have edit or edit.state rights.
			$filters['published'] = 1;
		}

		$results = JHelperTags::searchTags($filters);

		if ($results)
		{
			// Output a JSON object
			echo json_encode($results);
		}

		$app->close();
	}
}
PK�|!]��'��controllers/tag.phpnu&1i�<?php
/**
 * @package     Joomla.Administrator
 * @subpackage  com_tags
 *
 * @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;

/**
 * The Tag Controller
 *
 * @since  3.1
 */
class TagsControllerTag extends JControllerForm
{
	/**
	 * Method to check if you can add a new record.
	 *
	 * @param   array  $data  An array of input data.
	 *
	 * @return  boolean
	 *
	 * @since   3.1
	 */
	protected function allowAdd($data = array())
	{
		$user = JFactory::getUser();

		return $user->authorise('core.create', 'com_tags');
	}

	/**
	 * Method to check if you can edit a record.
	 *
	 * @param   array   $data  An array of input data.
	 * @param   string  $key   The name of the key for the primary key.
	 *
	 * @return  boolean
	 *
	 * @since   3.1
	 */
	protected function allowEdit($data = array(), $key = 'id')
	{
		// Since there is no asset tracking and no categories, revert to the component permissions.
		return parent::allowEdit($data, $key);
	}

	/**
	 * Method to run batch operations.
	 *
	 * @param   object  $model  The model.
	 *
	 * @return  boolean	 True if successful, false otherwise and internal error is set.
	 *
	 * @since   3.1
	 */
	public function batch($model = null)
	{
		$this->checkToken();

		// Set the model
		$model = $this->getModel('Tag');

		// Preset the redirect
		$this->setRedirect('index.php?option=com_tags&view=tags');

		return parent::batch($model);
	}
}
PK�|!](��11
access.xmlnu&1i�<?xml version="1.0" encoding="utf-8" ?>
<access component="com_tags">
	<section name="component">
		<action name="core.admin" title="JACTION_ADMIN" description="JACTION_ADMIN_COMPONENT_DESC" />
		<action name="core.options" title="JACTION_OPTIONS" description="JACTION_OPTIONS_COMPONENT_DESC" />
		<action name="core.manage" title="JACTION_MANAGE" description="JACTION_MANAGE_COMPONENT_DESC" />
		<action name="core.create" title="JACTION_CREATE" description="JACTION_CREATE_COMPONENT_DESC" />
		<action name="core.delete" title="JACTION_DELETE" description="JACTION_DELETE_COMPONENT_DESC" />
		<action name="core.edit" title="JACTION_EDIT" description="JACTION_EDIT_COMPONENT_DESC" />
		<action name="core.edit.state" title="JACTION_EDITSTATE" description="JACTION_EDITSTATE_COMPONENT_DESC" />
	</section>
</access>
PK�|!]�x���tags.xmlnu&1i�<?xml version="1.0" encoding="utf-8"?>
<extension type="component" version="3.1" method="upgrade">
	<name>com_tags</name>
	<author>Joomla! Project</author>
	<creationDate>December 2013</creationDate>
	<copyright>(C) 2013 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.1.0</version>
	<description>COM_TAGS_XML_DESCRIPTION</description>

	<files folder="site">
		<filename>controller.php</filename>
		<filename>metadata.xml</filename>
		<filename>newsfeeds.php</filename>
		<filename>router.php</filename>
		<folder>helpers</folder>
		<folder>models</folder>
		<folder>views</folder>
	</files>
	<languages folder="site">
		<language tag="en-GB">language/en-GB.com_tags.ini</language>
	</languages>
	<administration>
		<files folder="admin">
			<filename>tags.php</filename>
			<filename>config.xml</filename>
			<filename>controller.php</filename>
			<folder>controllers</folder>
			<folder>helpers</folder>
			<folder>models</folder>
			<folder>views</folder>
		</files>
		<languages folder="admin">
			<language tag="en-GB">language/en-GB.com_tags.ini</language>
			<language tag="en-GB">language/en-GB.com_tags.sys.ini</language>
		</languages>
		<menu link="option=com_tags" img="class:tags">com_tags</menu>

	</administration>
</extension>
PK�|!]��/�)�)
config.xmlnu&1i�<?xml version="1.0" encoding="utf-8"?>
<config>
	<fieldset
		name="taglist"
		label="COM_TAGS_CONFIG_TAG_SETTINGS_LABEL"
		description="COM_TAGS_CONFIG_TAG_SETTINGS_DESC">

		<field
			name="tag_layout"
			type="componentlayout"
			label="COM_TAGS_CONFIG_TAGGED_ITEMS_FIELD_LAYOUT_LABEL"
			description="COM_TAGS_CONFIG_TAGGED_ITEMS_FIELD_LAYOUT_DESC"
			menuitems="true"
			extension="com_tags"
			view="tag"
		/>

		<field
			name="save_history"
			type="radio"
			label="JGLOBAL_SAVE_HISTORY_OPTIONS_LABEL"
			description="JGLOBAL_SAVE_HISTORY_OPTIONS_DESC"
			class="btn-group btn-group-yesno"
			default="0"
			>
			<option value="1">JYES</option>
			<option value="0">JNO</option>
		</field>

		<field
			name="history_limit"
			type="number"
			label="JGLOBAL_HISTORY_LIMIT_OPTIONS_LABEL"
			description="JGLOBAL_HISTORY_LIMIT_OPTIONS_DESC"
			filter="integer"
			default="5"
			showon="save_history:1"
		/>

		<field
			name="show_tag_title"
			type="radio"
			label="COM_TAGS_SHOW_TAG_TITLE_LABEL"
			description="COM_TAGS_SHOW_TAG_TITLE_DESC"
			class="btn-group btn-group-yesno"
			default="0"
			>
			<option value="1">JSHOW</option>
			<option value="0">JHIDE</option>
		</field>

		<field
			name="tag_list_show_tag_image"
			type="radio"
			label="COM_TAGS_SHOW_TAG_IMAGE_LABEL"
			description="COM_TAGS_SHOW_TAG_IMAGE_DESC"
			class="btn-group btn-group-yesno"
			default="1"
			>
			<option value="1">JSHOW</option>
			<option value="0">JHIDE</option>
		</field>

		<field
			name="tag_list_show_tag_description"
			type="radio"
			label="COM_TAGS_SHOW_TAG_DESCRIPTION_LABEL"
			description="COM_TAGS_SHOW_TAG_DESCRIPTION_DESC"
			class="btn-group btn-group-yesno"
			default="1"
			>
			<option value="1">JSHOW</option>
			<option value="0">JHIDE</option>
		</field>

		<field
			name="tag_list_image"
			type="media"
			label="COM_TAGS_TAG_LIST_MEDIA_LABEL"
			description="COM_TAGS_TAG_LIST_MEDIA_DESC"
		/>

		<field
			name="tag_list_orderby"
			type="list"
			label="JGLOBAL_FIELD_FIELD_ORDERING_LABEL"
			description="JGLOBAL_FIELD_FIELD_ORDERING_DESC"
			default="title"
			validate="options"
			>
			<option value="c.core_title">JGLOBAL_TITLE</option>
			<option value="match_count">COM_TAGS_MATCH_COUNT</option>
			<option value="c.core_created_time">JGLOBAL_CREATED_DATE</option>
			<option value="c.core_modified_time">JGLOBAL_MODIFIED_DATE</option>
			<option value="c.core_publish_up">JGLOBAL_PUBLISHED_DATE</option>
		</field>

		<field
			name="tag_list_orderby_direction"
			type="radio"
			label="JGLOBAL_ORDER_DIRECTION_LABEL"
			description="JGLOBAL_ORDER_DIRECTION_DESC"
			class="btn-group btn-group-yesno"
			default="ASC"
			>
			<option value="ASC">JGLOBAL_ORDER_ASCENDING</option>
			<option value="DESC">JGLOBAL_ORDER_DESCENDING</option>
		</field>

		<field
			name="show_headings"
			type="radio"
			label="COM_TAGS_TAG_LIST_SHOW_HEADINGS_LABEL"
			description="COM_TAGS_TAG_LIST_SHOW_HEADINGS_DESC"
			class="btn-group btn-group-yesno"
			default="1"
			>
			<option value="1">JSHOW</option>
			<option value="0">JHIDE</option>
		</field>

		<field
			name="tag_list_show_date"
			type="list"
			label="COM_TAGS_TAG_LIST_SHOW_DATE_DESC"
			description="COM_TAGS_TAG_LIST_SHOW_DATE_LABEL"
			default="0"
			validate="options"
			>
			<option value="0">JHIDE</option>
			<option value="created">JGLOBAL_CREATED</option>
			<option value="modified">JGLOBAL_MODIFIED</option>
			<option value="published">JPUBLISHED</option>
		</field>

		<field
			name="tag_list_show_item_image"
			type="radio"
			label="COM_TAGS_SHOW_ITEM_IMAGE_LABEL"
			description="COM_TAGS_SHOW_ITEM_IMAGE_DESC"
			class="btn-group btn-group-yesno"
			default="1"
			>
			<option value="1">JSHOW</option>
			<option value="0">JHIDE</option>
		</field>

		<field
			name="tag_list_show_item_description"
			type="radio"
			label="COM_TAGS_TAG_LIST_SHOW_ITEM_DESCRIPTION_LABEL"
			description="COM_TAGS_TAG_LIST_SHOW_ITEM_DESCRIPTION_DESC"
			class="btn-group btn-group-yesno"
			>
			<option value="1">JSHOW</option>
			<option value="0">JHIDE</option>
		</field>

		<field
			name="tag_list_item_maximum_characters"
			type="number"
			label="COM_TAGS_LIST_MAX_CHARACTERS_LABEL"
			description="COM_TAGS_LIST_MAX_CHARACTERS_DESC"
			filter="integer"
			showon="tag_list_show_item_description:1"
		/>

	</fieldset>

	<fieldset
		name="tagselection"
		label="COM_TAGS_CONFIG_SELECTION_SETTINGS_LABEL"
		description="COM_TAGS_CONFIG_SELECTION_SETTINGS_DESC">

		<field
			name="min_term_length"
			type="integer"
			label="COM_TAGS_CONFIG_TAG_MIN_LENGTH_LABEL"
			description="COM_TAGS_CONFIG_TAG_MIN_LENGTH_DESC"
			first="1"
			last="3"
			step="1"
			default="3"
		/>

		<field
			name="return_any_or_all"
			type="radio"
			label="COM_TAGS_SEARCH_TYPE_LABEL"
			description="COM_TAGS_SEARCH_TYPE_DESC"
			class="btn-group btn-group-yesno"
			default="1"
			>
			<option value="1">COM_TAGS_ANY</option>
			<option value="0">COM_TAGS_ALL</option>
		</field>

		<field
			name="include_children"
			type="radio"
			label="COM_TAGS_INCLUDE_CHILDREN_LABEL"
			description="COM_TAGS_INCLUDE_CHILDREN_DESC"
			class="btn-group btn-group-yesno"
			default="0"
			>
			<option value="1">COM_TAGS_INCLUDE</option>
			<option value="0">COM_TAGS_EXCLUDE</option>
		</field>

		<field
			name="maximum"
			type="number"
			label="COM_TAGS_LIST_MAX_LABEL"
			description="COM_TAGS_LIST_MAX_DESC"
			default="200"
			filter="integer"
		/>

		<field
			name="tag_list_language_filter"
			type="contentlanguage"
			label="COM_TAGS_FIELD_LANGUAGE_FILTER_LABEL"
			description="COM_TAGS_FIELD_LANGUAGE_FILTER_DESC"
			default="all"
			>
			<option value="all">JALL</option>
			<option value="current_language">JCURRENT</option>
		</field>

	</fieldset>

	<fieldset
		name="alltags"
		label="COM_TAGS_CONFIG_ALL_TAGS_SETTINGS_LABEL"
		description="COM_TAGS_CONFIG_ALL_TAGS_SETTINGS_DESC">

		<field
			name="tags_layout"
			type="componentlayout"
			label="COM_TAGS_CONFIG_ALL_TAGS_FIELD_LAYOUT_LABEL"
			description="COM_TAGS_CONFIG_ALL_TAGS_FIELD_LAYOUT_DESC"
			menuitems="true"
			extension="com_tags"
			view="tags"
		/>

		<field
			name="all_tags_orderby"
			type="list"
			label="JGLOBAL_FIELD_FIELD_ORDERING_LABEL"
			description="JGLOBAL_FIELD_FIELD_ORDERING_DESC"
			default="title"
			validate="options"
			>
			<option value="title">JGLOBAL_TITLE</option>
			<option value="hits">JGLOBAL_HITS</option>
			<option value="created_time">JGLOBAL_CREATED_DATE</option>
			<option value="modified_time">JGLOBAL_MODIFIED_DATE</option>
			<option value="publish_up">JGLOBAL_PUBLISHED_DATE</option>
		</field>

		<field
			name="all_tags_orderby_direction"
			type="radio"
			label="JGLOBAL_ORDER_DIRECTION_LABEL"
			description="JGLOBAL_ORDER_DIRECTION_DESC"
			class="btn-group btn-group-yesno"
			default="ASC"
			>
			<option value="ASC">JGLOBAL_ORDER_ASCENDING</option>
			<option value="DESC">JGLOBAL_ORDER_DESCENDING</option>
		</field>

		<field
			name="all_tags_show_tag_image"
			type="radio"
			label="COM_TAGS_SHOW_ITEM_IMAGE_LABEL"
			description="COM_TAGS_SHOW_ITEM_IMAGE_DESC"
			class="btn-group btn-group-yesno"
			default="1"
			>
			<option value="1">JSHOW</option>
			<option value="0">JHIDE</option>
		</field>

		<field
			name="all_tags_show_tag_description"
			type="radio"
			label="COM_TAGS_SHOW_ITEM_DESCRIPTION_LABEL"
			description="COM_TAGS_SHOW_ITEM_DESCRIPTION_DESC"
			class="btn-group btn-group-yesno"
			default="1"
			>
			<option value="1">JSHOW</option>
			<option value="0">JHIDE</option>
		</field>

		<field
			name="all_tags_tag_maximum_characters"
			type="number"
			label="COM_TAGS_LIST_MAX_CHARACTERS_LABEL"
			description="COM_TAGS_LIST_MAX_CHARACTERS_DESC"
			filter="integer"
			showon="all_tags_show_tag_description:1"
		/>

		<field
			name="all_tags_show_tag_hits"
			type="radio"
			label="JGLOBAL_HITS"
			description="COM_TAGS_FIELD_CONFIG_HITS_DESC"
			class="btn-group btn-group-yesno"
			default="0"
			>
			<option value="1">JSHOW</option>
			<option value="0">JHIDE</option>
		</field>

	</fieldset>

	<fieldset
		name="shared"
		label="COM_TAGS_CONFIG_SHARED_SETTINGS_LABEL"
		description="COM_TAGS_CONFIG_SHARED_SETTINGS_DESC">

		<field
			name="filter_field"
			type="radio"
			label="JGLOBAL_FILTER_FIELD_LABEL"
			description="JGLOBAL_FILTER_FIELD_DESC"
			class="btn-group btn-group-yesno"
			default="1"
			>
			<option value="1">JSHOW</option>
			<option value="0">JHIDE</option>
		</field>

		<field
			name="show_pagination_limit"
			type="radio"
			label="JGLOBAL_DISPLAY_SELECT_LABEL"
			description="JGLOBAL_DISPLAY_SELECT_DESC"
			default="1"
			class="btn-group btn-group-yesno"
			>
			<option value="1">JSHOW</option>
			<option value="0">JHIDE</option>
		</field>

		<field
			name="show_pagination"
			type="list"
			label="JGLOBAL_PAGINATION_LABEL"
			description="JGLOBAL_PAGINATION_DESC"
			default="2"
			>
			<option value="1">JSHOW</option>
			<option value="0">JHIDE</option>
			<option value="2">JGLOBAL_AUTO</option>
		</field>

		<field
			name="show_pagination_results"
			type="radio"
			label="JGLOBAL_PAGINATION_RESULTS_LABEL"
			description="JGLOBAL_PAGINATION_RESULTS_DESC"
			class="btn-group btn-group-yesno"
			default="1"
			showon="show_pagination:1,2"
			>
			<option value="1">JSHOW</option>
			<option value="0">JHIDE</option>
		</field>

	</fieldset>

	<fieldset
		name="data_entry"
		label="COM_TAGS_CONFIG_DATA_ENTRY_SETTINGS_LABEL"
		description="COM_TAGS_CONFIG_DATA_ENTRY_SETTINGS_DESC">

		<field
			name="tag_field_ajax_mode"
			type="radio"
			label="COM_TAGS_TAG_FIELD_MODE_LABEL"
			description="COM_TAGS_TAG_FIELD_MODE_DESC"
			class="btn-group btn-group-yesno"
			default="1"
			>
			<option value="1">COM_TAGS_TAG_FIELD_MODE_AJAX</option>
			<option value="0">COM_TAGS_TAG_FIELD_MODE_NESTED</option>
		</field>

	</fieldset>

	<fieldset
		name="integration"
		label="JGLOBAL_INTEGRATION_LABEL"
		description="COM_TAGS_CONFIG_INTEGRATION_SETTINGS_DESC"
	>
		<field
			name="integration_newsfeeds"
			type="note"
			label="JGLOBAL_FEED_TITLE"
		/>

		<field
			name="show_feed_link"
			type="radio"
			label="JGLOBAL_SHOW_FEED_LINK_LABEL"
			description="JGLOBAL_SHOW_FEED_LINK_DESC"
			class="btn-group btn-group-yesno"
			default="1"
			>
			<option value="1">JSHOW</option>
			<option value="0">JHIDE</option>
		</field>

	</fieldset>

	<fieldset
		name="permissions"
		label="JCONFIG_PERMISSIONS_LABEL"
		description="JCONFIG_PERMISSIONS_DESC"
		>

		<field
			name="rules"
			type="rules"
			label="JCONFIG_PERMISSIONS_LABEL"
			filter="rules"
			validate="rules"
			component="com_tags"
			section="component"
		/>
	</fieldset>
</config>
PK�|!]=�ӻ��tags.phpnu&1i�<?php
/**
 * @package     Joomla.Site
 * @subpackage  com_tags
 *
 * @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;

JLoader::register('TagsHelperRoute', JPATH_COMPONENT . '/helpers/route.php');

$controller = JControllerLegacy::getInstance('Tags');
$controller->execute(JFactory::getApplication()->input->get('task'));
$controller->redirect();
PK�|!]�C%tables/tag.phpnu&1i�<?php
/**
 * @package     Joomla.Administrator
 * @subpackage  com_tags
 *
 * @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;

use Joomla\Registry\Registry;
use Joomla\String\StringHelper;

/**
 * Tags table
 *
 * @since  3.1
 */
class TagsTableTag extends JTableNested
{
	/**
	 * Constructor
	 *
	 * @param   JDatabaseDriver  $db  A database connector object
	 */
	public function __construct($db)
	{
		parent::__construct('#__tags', 'id', $db);

		JTableObserverContenthistory::createObserver($this, array('typeAlias' => 'com_tags.tag'));
	}

	/**
	 * Overloaded bind function
	 *
	 * @param   array  $array   Named array
	 * @param   mixed  $ignore  An optional array or space separated list of properties
	 * to ignore while binding.
	 *
	 * @return  mixed  Null if operation was satisfactory, otherwise returns an error string
	 *
	 * @see     JTable::bind
	 * @since   3.1
	 */
	public function bind($array, $ignore = '')
	{
		if (isset($array['params']) && is_array($array['params']))
		{
			$registry = new Registry($array['params']);
			$array['params'] = (string) $registry;
		}

		if (isset($array['metadata']) && is_array($array['metadata']))
		{
			$registry = new Registry($array['metadata']);
			$array['metadata'] = (string) $registry;
		}

		if (isset($array['urls']) && is_array($array['urls']))
		{
			$registry = new Registry($array['urls']);
			$array['urls'] = (string) $registry;
		}

		if (isset($array['images']) && is_array($array['images']))
		{
			$registry = new Registry($array['images']);
			$array['images'] = (string) $registry;
		}

		return parent::bind($array, $ignore);
	}

	/**
	 * Overloaded check method to ensure data integrity.
	 *
	 * @return  boolean  True on success.
	 *
	 * @since   3.1
	 * @throws  UnexpectedValueException
	 */
	public function check()
	{
		// Check for valid name.
		if (trim($this->title) == '')
		{
			throw new UnexpectedValueException(sprintf('The title is empty'));
		}

		if (empty($this->alias))
		{
			$this->alias = $this->title;
		}

		$this->alias = JApplicationHelper::stringURLSafe($this->alias, $this->language);

		if (trim(str_replace('-', '', $this->alias)) == '')
		{
			$this->alias = JFactory::getDate()->format('Y-m-d-H-i-s');
		}

		// Check the publish down date is not earlier than publish up.
		if ((int) $this->publish_down > 0 && $this->publish_down < $this->publish_up)
		{
			throw new UnexpectedValueException(sprintf('End publish date is before start publish date.'));
		}

		// Clean up keywords -- eliminate extra spaces between phrases
		// and cr (\r) and lf (\n) characters from string
		if (!empty($this->metakey))
		{
			// Only process if not empty
			// Define array of characters to remove
			$bad_characters = array("\n", "\r", "\"", '<', '>');

			// Remove bad characters
			$after_clean = StringHelper::str_ireplace($bad_characters, '', $this->metakey);

			// Create array using commas as delimiter
			$keys = explode(',', $after_clean);
			$clean_keys = array();

			foreach ($keys as $key)
			{
				if (trim($key))
				{
					// Ignore blank keywords
					$clean_keys[] = trim($key);
				}
			}

			// Put array back together delimited by ", "
			$this->metakey = implode(', ', $clean_keys);
		}

		// Clean up description -- eliminate quotes and <> brackets
		if (!empty($this->metadesc))
		{
			// Only process if not empty
			$bad_characters = array("\"", '<', '>');
			$this->metadesc = StringHelper::str_ireplace($bad_characters, '', $this->metadesc);
		}

		// Not Null sanity check
		$date = JFactory::getDate();

		if (empty($this->params))
		{
			$this->params = '{}';
		}

		if (empty($this->metadesc))
		{
			$this->metadesc = '';
		}

		if (empty($this->metakey))
		{
			$this->metakey = '';
		}

		if (empty($this->metadata))
		{
			$this->metadata = '{}';
		}

		if (empty($this->urls))
		{
			$this->urls = '{}';
		}

		if (empty($this->images))
		{
			$this->images = '{}';
		}

		if (!(int) $this->checked_out_time)
		{
			$this->checked_out_time = $date->toSql();
		}

		if (!(int) $this->modified_time)
		{
			$this->modified_time = $date->toSql();
		}

		if (!(int) $this->modified_time)
		{
			$this->modified_time = $date->toSql();
		}

		if (!(int) $this->publish_up)
		{
			$this->publish_up = $date->toSql();
		}

		if (!(int) $this->publish_down)
		{
			$this->publish_down = $date->toSql();
		}

		return true;
	}

	/**
	 * Overriden JTable::store to set modified data and user id.
	 *
	 * @param   boolean  $updateNulls  True to update fields even if they are null.
	 *
	 * @return  boolean  True on success.
	 *
	 * @since   3.1
	 */
	public function store($updateNulls = false)
	{
		$date = JFactory::getDate();
		$user = JFactory::getUser();

		$this->modified_time = $date->toSql();

		if ($this->id)
		{
			// Existing item
			$this->modified_user_id = $user->get('id');
		}
		else
		{
			// New tag. A tag created and created_by field can be set by the user,
			// so we don't touch either of these if they are set.
			if (!(int) $this->created_time)
			{
				$this->created_time = $date->toSql();
			}

			if (empty($this->created_user_id))
			{
				$this->created_user_id = $user->get('id');
			}
		}

		// Verify that the alias is unique
		$table = JTable::getInstance('Tag', 'TagsTable', array('dbo' => $this->_db));

		if ($table->load(array('alias' => $this->alias)) && ($table->id != $this->id || $this->id == 0))
		{
			$this->setError(JText::_('COM_TAGS_ERROR_UNIQUE_ALIAS'));

			return false;
		}

		return parent::store($updateNulls);
	}

	/**
	 * Method to delete a node and, optionally, its child nodes from the table.
	 *
	 * @param   integer  $pk        The primary key of the node to delete.
	 * @param   boolean  $children  True to delete child nodes, false to move them up a level.
	 *
	 * @return  boolean  True on success.
	 *
	 * @since   3.1
	 */
	public function delete($pk = null, $children = false)
	{
		$return = parent::delete($pk, $children);

		if ($return)
		{
			$helper = new JHelperTags;
			$helper->tagDeleteInstances($pk);
		}

		return $return;
	}
}
PK�|!]��1�yycontroller.phpnu&1i�<?php
/**
 * @package     Joomla.Site
 * @subpackage  com_tags
 *
 * @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;

/**
 * Tags Component Controller
 *
 * @since  3.1
 */
class TagsController extends JControllerLegacy
{
	/**
	 * Method to display a view.
	 *
	 * @param   boolean        $cachable   If true, the view output will be cached
	 * @param   mixed|boolean  $urlparams  An array of safe URL parameters and their variable types, for valid values see {@link JFilterInput::clean()}.
	 *
	 * @return  JControllerLegacy  This object to support chaining.
	 *
	 * @since   3.1
	 */
	public function display($cachable = false, $urlparams = false)
	{
		$user = JFactory::getUser();

		// Set the default view name and format from the Request.
		$vName = $this->input->get('view', 'tags');
		$this->input->set('view', $vName);

		if ($user->get('id') || ($this->input->getMethod() === 'POST' && $vName === 'tags'))
		{
			$cachable = false;
		}

		$safeurlparams = array(
			'id'               => 'ARRAY',
			'type'             => 'ARRAY',
			'limit'            => 'UINT',
			'limitstart'       => 'UINT',
			'filter_order'     => 'CMD',
			'filter_order_Dir' => 'CMD',
			'lang'             => 'CMD'
		);

		return parent::display($cachable, $safeurlparams);
	}
}
PK�|!]�L��
�
models/forms/filter_tags.xmlnu&1i�<?xml version="1.0" encoding="utf-8"?>
<form>
	<fields name="filter">
		<field
			name="search"
			type="text"
			inputmode="search"
			label="COM_TAGS_FILTER_SEARCH_LABEL"
			description="COM_TAGS_FILTER_SEARCH_DESC"
			hint="JSEARCH_FILTER"
		/>
		<field
			name="published"
			type="status"
			label="COM_TAGS_FILTER_PUBLISHED"
			description="COM_TAGS_FILTER_PUBLISHED_DESC"
			onchange="this.form.submit();"
			>
			<option value="">JOPTION_SELECT_PUBLISHED</option>
		</field>
		<field
			name="access"
			type="accesslevel"
			label="JOPTION_FILTER_ACCESS"
			description="JOPTION_FILTER_ACCESS_DESC"
			onchange="this.form.submit();"
			>
			<option value="">JOPTION_SELECT_ACCESS</option>
		</field>
		<field
			name="language"
			type="contentlanguage"
			label="JOPTION_FILTER_LANGUAGE"
			description="JOPTION_FILTER_LANGUAGE_DESC"
			onchange="this.form.submit();"
			>
			<option value="">JOPTION_SELECT_LANGUAGE</option>
			<option value="*">JALL</option>
		</field>
        <field
			name="level"
			type="integer"
			label="JOPTION_FILTER_LEVEL"
			description="JOPTION_FILTER_LEVEL_DESC"
			first="1"
			last="10"
			step="1"
			onchange="this.form.submit();"
			>
			<option value="">JOPTION_SELECT_MAX_LEVELS</option>
        </field>
		<field
			name="extension"
			type="aliastag"
			label="COM_TAGS_FILTER_ALIASTYPE_LABEL"
			description="COM_TAGS_FIELD_ALIASTYPE_DESC"
			onchange="this.form.submit();"
			>
			<option value="">COM_TAGS_SELECT_TAGTYPE</option>
		</field>
	</fields>
	<fields name="list">
		<field
            name="fullordering"
			type="list"
			label="COM_TAGS_LIST_FULL_ORDERING"
			description="COM_TAGS_LIST_FULL_ORDERING_DESC"
			onchange="this.form.submit();"
			default="a.lft ASC"
			validate="options"
			>
			<option value="">JGLOBAL_SORT_BY</option>
			<option value="a.lft ASC">JGRID_HEADING_ORDERING_ASC</option>
			<option value="a.lft DESC">JGRID_HEADING_ORDERING_DESC</option>
			<option value="a.published ASC">JSTATUS_ASC</option>
			<option value="a.published DESC">JSTATUS_DESC</option>
			<option value="a.title ASC">JGLOBAL_TITLE_ASC</option>
			<option value="a.title DESC">JGLOBAL_TITLE_DESC</option>
			<option value="a.access ASC">JGRID_HEADING_ACCESS_ASC</option>
			<option value="a.access DESC">JGRID_HEADING_ACCESS_DESC</option>
			<option value="a.language ASC">JGRID_HEADING_LANGUAGE_ASC</option>
			<option value="a.language DESC">JGRID_HEADING_LANGUAGE_DESC</option>
			<option value="a.id ASC">JGRID_HEADING_ID_ASC</option>
			<option value="a.id DESC">JGRID_HEADING_ID_DESC</option>
		</field>
		<field
			name="limit"
			type="limitbox"
			label="COM_TAGS_LIST_LIMIT"
			description="COM_TAGS_LIST_LIMIT_DESC"
			class="input-mini"
			default="25"
			onchange="this.form.submit();"
		/>
	</fields>
</form>
PK�|!]��.��models/forms/tag.xmlnu&1i�<?xml version="1.0" encoding="utf-8"?>
<form>
	<field
		name="id"
		type="number"
		label="JGLOBAL_FIELD_ID_LABEL"
		description="JGLOBAL_FIELD_ID_DESC"
		default="0"
		class="readonly"
		readonly="true"
	/>

	<field
		name="hits"
		type="number"
		label="JGLOBAL_HITS"
		description="COM_TAGS_FIELD_HITS_DESC"
		class="readonly"
		default="0"
		readonly="true"
		filter="unset"
	/>

	<field
		name="parent_id"
		type="tag"
		label="COM_TAGS_FIELD_PARENT_LABEL"
		description="COM_TAGS_FIELD_PARENT_DESC"
		mode="nested"
		validate="notequals"
		field="id"
		parent="parent"
		>
		<option value="1">JNONE</option>
	</field>

	<field
		name="lft"
		type="hidden"
		filter="unset"
	/>

	<field
		name="rgt"
		type="hidden"
		filter="unset"
	/>

	<field
		name="level"
		type="hidden"
		filter="unset"
	/>

	<field
		name="path"
		type="text"
		label="CATEGORIES_PATH_LABEL"
		description="CATEGORIES_PATH_DESC"
		class="readonly"
		size="40"
		readonly="true"
	/>

	<field
		name="title"
		type="text"
		label="JGLOBAL_TITLE"
		description="JFIELD_TITLE_DESC"
		class="input-xxlarge input-large-text"
		size="40"
		required="true"
	/>

	<field
		name="note"
		type="text"
		label="COM_TAGS_FIELD_NOTE_LABEL"
		description="COM_TAGS_FIELD_NOTE_DESC"
		maxlength="255"
		class="span12"
		size="40"
	/>

	<field
		name="description"
		type="editor"
		label="JGLOBAL_DESCRIPTION"
		description="COM_TAGS_DESCRIPTION_DESC"
		filter="JComponentHelper::filterText"
		buttons="true"
		hide="readmore,pagebreak"
	/>

	<field
		name="published"
		type="list"
		label="JSTATUS"
		description="JFIELD_PUBLISHED_DESC"
		class="chzn-color-state"
		default="1"
		size="1"
		>
		<option value="1">JPUBLISHED</option>
		<option value="0">JUNPUBLISHED</option>
		<option value="2">JARCHIVED</option>
		<option value="-2">JTRASHED</option>
	</field>

	<field
		name="checked_out"
		type="hidden"
		filter="unset"
	/>

	<field
		name="checked_out_time"
		type="hidden"
		filter="unset"
	/>

	<field
		name="access"
		type="accesslevel"
		label="JFIELD_ACCESS_LABEL"
		description="JFIELD_ACCESS_DESC"
	/>

	<field
		name="metadesc"
		type="textarea"
		label="JFIELD_META_DESCRIPTION_LABEL"
		description="JFIELD_META_DESCRIPTION_DESC"
		rows="3"
		cols="40"
	/>

	<field
		name="metakey"
		type="textarea"
		label="JFIELD_META_KEYWORDS_LABEL"
		description="JFIELD_META_KEYWORDS_DESC"
		rows="3"
		cols="40"
	/>

	<field
		name="alias"
		type="text"
		label="JFIELD_ALIAS_LABEL"
		description="JFIELD_ALIAS_DESC"
		hint="JFIELD_ALIAS_PLACEHOLDER"
		size="40"
	/>

	<field
		name="created_user_id"
		type="user"
		label="JGLOBAL_FIELD_CREATED_BY_LABEL"
		description="JGLOBAL_FIELD_CREATED_BY_DESC"
	/>

	<field
		name="created_by_alias"
		type="text"
		label="JGLOBAL_FIELD_CREATED_BY_ALIAS_LABEL"
		description="JGLOBAL_FIELD_CREATED_BY_ALIAS_DESC"
		labelclass="control-label"
		size="20"
	/>

	<field
		name="created_time"
		type="calendar"
		label="JGLOBAL_CREATED_DATE"
		description="COM_TAGS_FIELD_CREATED_DATE_DESC"
		class="readonly"
		translateformat="true"
		showtime="true"
		filter="user_utc"
		readonly="true"
	/>

	<field
		name="modified_user_id"
		type="user"
		label="JGLOBAL_FIELD_MODIFIED_BY_LABEL"
		class="readonly"
		readonly="true"
		filter="unset"
	/>

	<field
		name="modified_time"
		type="calendar"
		label="JGLOBAL_FIELD_MODIFIED_LABEL"
		description="COM_TAGS_FIELD_MODIFIED_DESC"
		class="readonly"
		translateformat="true"
		showtime="true"
		filter="user_utc"
		readonly="true"
	/>

	<field
		name="language"
		type="contentlanguage"
		label="JFIELD_LANGUAGE_LABEL"
		description="COM_TAGS_FIELD_LANGUAGE_DESC"
		>
		<option value="*">JALL</option>
	</field>

	<field
		name="version_note"
		type="text"
		label="JGLOBAL_FIELD_VERSION_NOTE_LABEL"
		description="JGLOBAL_FIELD_VERSION_NOTE_DESC"
		maxlength="255"
		class="span12" size="45"
		labelclass="control-label"
	/>

	<fields name="params" label="JGLOBAL_FIELDSET_DISPLAY_OPTIONS">
		<fieldset
			name="basic"
			label="COM_TAGS_BASIC_FIELDSET_LABEL"
		>

			<field
				name="tag_layout"
				type="componentlayout"
				label="JFIELD_ALT_LAYOUT_LABEL"
				description="JFIELD_ALT_COMPONENT_LAYOUT_DESC"
				labelclass="control-label"
				useglobal="true"
				extension="com_tags"
				view="tag"
			/>

			<field
				name="tag_link_class"
				type="text"
				label="COM_TAGS_FIELD_TAG_LINK_CLASS"
				description="COM_TAGS_FIELD_TAG_LINK_CLASS_DESC"
				labelclass="control-label"
				size="20"
				default="label label-info"
			/>

		</fieldset>
	</fields>

	<fields name="images">
		<fieldset name="images" label="JGLOBAL_FIELDSET_IMAGE_OPTIONS">
			<field
				name="image_intro"
				type="media"
				label="COM_TAGS_FIELD_INTRO_LABEL"
				description="COM_TAGS_FIELD_INTRO_DESC"
				labelclass="control-label"
			/>

			<field
				name="float_intro"
				type="list"
				label="COM_TAGS_FLOAT_LABEL"
				description="COM_TAGS_FLOAT_DESC"
				labelclass="control-label"
				>
				<option value="">JGLOBAL_SELECT_AN_OPTION</option>
				<option value="right">COM_TAGS_RIGHT</option>
				<option value="left">COM_TAGS_LEFT</option>
				<option value="none">COM_TAGS_NONE</option>
			</field>

			<field
				name="image_intro_alt"
				type="text"
				label="COM_TAGS_FIELD_IMAGE_ALT_LABEL"
				description="COM_TAGS_FIELD_IMAGE_ALT_DESC"
				labelclass="control-label"
				size="20"
			/>

			<field
				name="image_intro_caption"
				type="text"
				label="COM_TAGS_FIELD_IMAGE_CAPTION_LABEL"
				description="COM_TAGS_FIELD_IMAGE_CAPTION_DESC"
				size="20"
				labelclass="control-label"
			/>

			<field
				name="spacer1"
				type="spacer"
				hr="true"
			/>

			<field
				name="image_fulltext"
				type="media"
				label="COM_TAGS_FIELD_FULL_LABEL"
				description="COM_TAGS_FIELD_FULL_DESC"
				labelclass="control-label"
			/>

			<field
				name="float_fulltext"
				type="list"
				label="COM_TAGS_FLOAT_LABEL"
				description="COM_TAGS_FLOAT_DESC"
				labelclass="control-label"
				>
				<option value="">JGLOBAL_SELECT_AN_OPTION</option>
				<option value="right">COM_TAGS_RIGHT</option>
				<option value="left">COM_TAGS_LEFT</option>
				<option value="none">COM_TAGS_NONE</option>
			</field>

			<field
				name="image_fulltext_alt"
				type="text"
				label="COM_TAGS_FIELD_IMAGE_ALT_LABEL"
				description="COM_TAGS_FIELD_IMAGE_ALT_DESC"
				labelclass="control-label"
				size="20"
			/>

			<field
				name="image_fulltext_caption"
				type="text"
				label="COM_TAGS_FIELD_IMAGE_CAPTION_LABEL"
				description="COM_TAGS_FIELD_IMAGE_CAPTION_DESC"
				labelclass="control-label"
				size="20"
			/>
		</fieldset>
	</fields>

	<fields name="metadata" label="JGLOBAL_FIELDSET_METADATA_OPTIONS">
		<fieldset name="jmetadata" label="JGLOBAL_FIELDSET_METADATA_OPTIONS">

			<field
				name="author"
				type="text"
				label="JAUTHOR"
				description="JFIELD_METADATA_AUTHOR_DESC"
				size="30"
			/>

			<field
				name="robots"
				type="list"
				label="JFIELD_METADATA_ROBOTS_LABEL"
				description="JFIELD_METADATA_ROBOTS_DESC"
				>
				<option value="">JGLOBAL_USE_GLOBAL</option>
				<option value="index, follow"></option>
				<option value="noindex, follow"></option>
				<option value="index, nofollow"></option>
				<option value="noindex, nofollow"></option>
			</field>
		</fieldset>
	</fields>
</form>
PK�|!]�Ϙ##models/tag.phpnu&1i�<?php
/**
 * @package     Joomla.Site
 * @subpackage  com_tags
 *
 * @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;

use Joomla\Utilities\ArrayHelper;

/**
 * Tags Component Tag Model
 *
 * @since  3.1
 */
class TagsModelTag extends JModelList
{
	/**
	 * The tags that apply.
	 *
	 * @var    object
	 * @since  3.1
	 */
	protected $tag = null;

	/**
	 * The list of items associated with the tags.
	 *
	 * @var    array
	 * @since  3.1
	 */
	protected $items = null;

	/**
	 * Constructor.
	 *
	 * @param   array  $config  An optional associative array of configuration settings.
	 *
	 * @see     JController
	 * @since   3.1
	 */
	public function __construct($config = array())
	{
		if (empty($config['filter_fields']))
		{
			$config['filter_fields'] = array(
				'core_content_id', 'c.core_content_id',
				'core_title', 'c.core_title',
				'core_type_alias', 'c.core_type_alias',
				'core_checked_out_user_id', 'c.core_checked_out_user_id',
				'core_checked_out_time', 'c.core_checked_out_time',
				'core_catid', 'c.core_catid',
				'core_state', 'c.core_state',
				'core_access', 'c.core_access',
				'core_created_user_id', 'c.core_created_user_id',
				'core_created_time', 'c.core_created_time',
				'core_modified_time', 'c.core_modified_time',
				'core_ordering', 'c.core_ordering',
				'core_featured', 'c.core_featured',
				'core_language', 'c.core_language',
				'core_hits', 'c.core_hits',
				'core_publish_up', 'c.core_publish_up',
				'core_publish_down', 'c.core_publish_down',
				'core_images', 'c.core_images',
				'core_urls', 'c.core_urls',
				'match_count',
			);
		}

		parent::__construct($config);
	}

	/**
	 * Method to get a list of items for a list of tags.
	 *
	 * @return  mixed  An array of objects on success, false on failure.
	 *
	 * @since   3.1
	 */
	public function getItems()
	{
		// Invoke the parent getItems method to get the main list
		$items = parent::getItems();

		if (!empty($items))
		{
			foreach ($items as $item)
			{
				$item->link = TagsHelperRoute::getItemRoute(
					$item->content_item_id,
					$item->core_alias,
					$item->core_catid,
					$item->core_language,
					$item->type_alias,
					$item->router
				);

				// Get display date
				switch ($this->state->params->get('tag_list_show_date'))
				{
					case 'modified':
						$item->displayDate = $item->core_modified_time;
						break;

					case 'created':
						$item->displayDate = $item->core_created_time;
						break;

					default:
					case 'published':
						$item->displayDate = ($item->core_publish_up == 0) ? $item->core_created_time : $item->core_publish_up;
						break;
				}
			}
		}

		return $items;
	}

	/**
	 * Method to build an SQL query to load the list data of all items with a given tag.
	 *
	 * @return  string  An SQL query
	 *
	 * @since   3.1
	 */
	protected function getListQuery()
	{
		$tagId  = $this->getState('tag.id') ? : '';

		$typesr = $this->getState('tag.typesr');
		$orderByOption = $this->getState('list.ordering', 'c.core_title');
		$includeChildren = $this->state->params->get('include_children', 0);
		$orderDir = $this->getState('list.direction', 'ASC');
		$matchAll = $this->getState('params')->get('return_any_or_all', 1);
		$language = $this->getState('tag.language');
		$stateFilter = $this->getState('tag.state');

		// Optionally filter on language
		if (empty($language))
		{
			$language = JComponentHelper::getParams('com_tags')->get('tag_list_language_filter', 'all');
		}

		$tagsHelper = new JHelperTags;
		$query = $tagsHelper->getTagItemsQuery($tagId, $typesr, $includeChildren, $orderByOption, $orderDir, $matchAll, $language, $stateFilter);

		if ($this->state->get('list.filter'))
		{
			$query->where($this->_db->quoteName('c.core_title') . ' LIKE ' . $this->_db->quote('%' . $this->state->get('list.filter') . '%'));
		}

		return $query;
	}

	/**
	 * Method to auto-populate the model state.
	 *
	 * Note. Calling getState in this method will result in recursion.
	 *
	 * @param   string  $ordering   An optional ordering field.
	 * @param   string  $direction  An optional direction (asc|desc).
	 *
	 * @return  void
	 *
	 * @since   3.1
	 */
	protected function populateState($ordering = 'c.core_title', $direction = 'ASC')
	{
		$app = JFactory::getApplication();

		// Load the parameters.
		$params = $app->isClient('administrator') ? JComponentHelper::getParams('com_tags') : $app->getParams();

		$this->setState('params', $params);

		// Load state from the request.
		$ids = (array) $app->input->get('id', array(), 'string');

		if (count($ids) == 1)
		{
			$ids = explode(',', $ids[0]);
		}

		$ids = ArrayHelper::toInteger($ids);

		// Remove zero values resulting from bad input
		$ids = array_filter($ids);

		$pkString = implode(',', $ids);

		$this->setState('tag.id', $pkString);

		// Get the selected list of types from the request. If none are specified all are used.
		$typesr = $app->input->get('types', array(), 'array');

		if ($typesr)
		{
			// Implode is needed because the array can contain a string with a coma separated list of ids
			$typesr = implode(',', $typesr);

			// Sanitise
			$typesr = explode(',', $typesr);
			$typesr = ArrayHelper::toInteger($typesr);

			$this->setState('tag.typesr', $typesr);
		}

		$language = $app->input->getString('tag_list_language_filter');
		$this->setState('tag.language', $language);

		// List state information
		$format = $app->input->getWord('format');

		if ($format === 'feed')
		{
			$limit = $app->get('feed_limit');
		}
		else
		{
			$limit = $params->get('display_num', $app->get('list_limit', 20));
			$limit = $app->getUserStateFromRequest('global.list.limit', 'limit', $limit, 'uint');
		}

		$this->setState('list.limit', $limit);

		$offset = $app->input->get('limitstart', 0, 'uint');
		$this->setState('list.start', $offset);

		$itemid = $pkString . ':' . $app->input->get('Itemid', 0, 'int');
		$orderCol = $app->getUserStateFromRequest('com_tags.tag.list.' . $itemid . '.filter_order', 'filter_order', '', 'string');
		$orderCol = !$orderCol ? $this->state->params->get('tag_list_orderby', 'c.core_title') : $orderCol;

		if (!in_array($orderCol, $this->filter_fields))
		{
			$orderCol = 'c.core_title';
		}

		$this->setState('list.ordering', $orderCol);

		$listOrder = $app->getUserStateFromRequest('com_tags.tag.list.' . $itemid . '.filter_order_direction', 'filter_order_Dir', '', 'string');
		$listOrder = !$listOrder ? $this->state->params->get('tag_list_orderby_direction', 'ASC') : $listOrder;

		if (!in_array(strtoupper($listOrder), array('ASC', 'DESC', '')))
		{
			$listOrder = 'ASC';
		}

		$this->setState('list.direction', $listOrder);

		$this->setState('tag.state', 1);

		// Optional filter text
		$filterSearch = $app->getUserStateFromRequest('com_tags.tag.list.' . $itemid . '.filter_search', 'filter-search', '', 'string');
		$this->setState('list.filter', $filterSearch);
	}

	/**
	 * Method to get tag data for the current tag or tags
	 *
	 * @param   integer  $pk  An optional ID
	 *
	 * @return  object
	 *
	 * @since   3.1
	 */
	public function getItem($pk = null)
	{
		if (!isset($this->item))
		{
			$this->item = false;

			if (empty($pk))
			{
				$pk = $this->getState('tag.id');
			}

			// Get a level row instance.
			$table = JTable::getInstance('Tag', 'TagsTable');

			$idsArray = explode(',', $pk);

			// Attempt to load the rows into an array.
			foreach ($idsArray as $id)
			{
				try
				{
					$table->load($id);

					// Check published state.
					if ($published = $this->getState('tag.state'))
					{
						if ($table->published != $published)
						{
							continue;
						}
					}

					if (!in_array($table->access, JFactory::getUser()->getAuthorisedViewLevels()))
					{
						continue;
					}

					// Convert the JTable to a clean JObject.
					$properties = $table->getProperties(1);
					$this->item[] = ArrayHelper::toObject($properties, 'JObject');
				}
				catch (RuntimeException $e)
				{
					$this->setError($e->getMessage());

					return false;
				}
			}
		}

		if (!$this->item)
		{
			return JError::raiseError(404, JText::_('COM_TAGS_TAG_NOT_FOUND'));
		}

		return $this->item;
	}

	/**
	 * Increment the hit counter.
	 *
	 * @param   integer  $pk  Optional primary key of the article to increment.
	 *
	 * @return  boolean  True if successful; false otherwise and internal error set.
	 *
	 * @since   3.2
	 */
	public function hit($pk = 0)
	{
		$input    = JFactory::getApplication()->input;
		$hitcount = $input->getInt('hitcount', 1);

		if ($hitcount)
		{
			$pk    = (!empty($pk)) ? $pk : (int) $this->getState('tag.id');
			$table = JTable::getInstance('Tag', 'TagsTable');
			$table->hit($pk);

			// Load the table data for later
			$table->load($pk);

			if (!$table->hasPrimaryKey())
			{
				JError::raiseError(404, JText::_('COM_TAGS_TAG_NOT_FOUND'));
			}
		}

		return true;
	}
}
PK�|!]A�p���models/tags.phpnu&1i�<?php
/**
 * @package     Joomla.Site
 * @subpackage  com_tags
 *
 * @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;

use Joomla\Registry\Registry;

/**
 * This models supports retrieving a list of tags.
 *
 * @since  3.1
 */
class TagsModelTags extends JModelList
{
	/**
	 * Model context string.
	 *
	 * @var    string
	 * @since  3.1
	 */
	public $_context = 'com_tags.tags';

	/**
	 * Method to auto-populate the model state.
	 *
	 * @param   string  $ordering   An optional ordering field.
	 * @param   string  $direction  An optional direction (asc|desc).
	 *
	 * @return  void
	 *
	 * @note Calling getState in this method will result in recursion.
	 *
	 * @since   3.1
	 */
	protected function populateState($ordering = null, $direction = null)
	{
		$app = JFactory::getApplication('site');

		// Load state from the request.
		$pid = $app->input->getInt('parent_id');
		$this->setState('tag.parent_id', $pid);

		$language = $app->input->getString('tag_list_language_filter');
		$this->setState('tag.language', $language);

		$offset = $app->input->get('limitstart', 0, 'uint');
		$this->setState('list.offset', $offset);
		$app = JFactory::getApplication();

		$params = $app->getParams();
		$this->setState('params', $params);

		$this->setState('list.limit', $params->get('maximum', 200));

		$this->setState('filter.published', 1);
		$this->setState('filter.access', true);

		$user = JFactory::getUser();

		if ((!$user->authorise('core.edit.state', 'com_tags')) &&  (!$user->authorise('core.edit', 'com_tags')))
		{
			$this->setState('filter.published', 1);
		}

		// Optional filter text
		$itemid = $pid . ':' . $app->input->getInt('Itemid', 0);
		$filterSearch = $app->getUserStateFromRequest('com_tags.tags.list.' . $itemid . '.filter_search', 'filter-search', '', 'string');
		$this->setState('list.filter', $filterSearch);
	}

	/**
	 * Method to build an SQL query to load the list data.
	 *
	 * @return  string  An SQL query
	 *
	 * @since   1.6
	 */
	protected function getListQuery()
	{
		$app            = JFactory::getApplication('site');
		$user           = JFactory::getUser();
		$groups         = implode(',', $user->getAuthorisedViewLevels());
		$pid            = $this->getState('tag.parent_id');
		$orderby        = $this->state->params->get('all_tags_orderby', 'title');
		$published      = $this->state->params->get('published', 1);
		$orderDirection = $this->state->params->get('all_tags_orderby_direction', 'ASC');
		$language       = $this->getState('tag.language');

		// Create a new query object.
		$db    = $this->getDbo();
		$query = $db->getQuery(true);

		// Select required fields from the tags.
		$query->select('a.*, u.name as created_by_user_name, u.email')
			->from($db->quoteName('#__tags') . ' AS a')
			->join('LEFT', '#__users AS u ON a.created_user_id = u.id')
			->where($db->quoteName('a.access') . ' IN (' . $groups . ')');

		if (!empty($pid))
		{
			$query->where($db->quoteName('a.parent_id') . ' = ' . $pid);
		}

		// Exclude the root.
		$query->where($db->quoteName('a.parent_id') . ' <> 0');

		// Optionally filter on language
		if (empty($language))
		{
			$language = JComponentHelper::getParams('com_tags')->get('tag_list_language_filter', 'all');
		}

		if ($language !== 'all')
		{
			if ($language === 'current_language')
			{
				$language = JHelperContent::getCurrentLanguage();
			}

			$query->where($db->quoteName('language') . ' IN (' . $db->quote($language) . ', ' . $db->quote('*') . ')');
		}

		// List state information
		$format = $app->input->getWord('format');

		if ($format === 'feed')
		{
			$limit = $app->get('feed_limit');
		}
		else
		{
			if ($this->state->params->get('show_pagination_limit'))
			{
				$limit = $app->getUserStateFromRequest('global.list.limit', 'limit', $app->get('list_limit'), 'uint');
			}
			else
			{
				$limit = $this->state->params->get('maximum', 20);
			}
		}

		$this->setState('list.limit', $limit);

		$offset = $app->input->get('limitstart', 0, 'uint');
		$this->setState('list.start', $offset);

		// Optionally filter on entered value
		if ($this->state->get('list.filter'))
		{
			$query->where($db->quoteName('a.title') . ' LIKE ' . $db->quote('%' . $this->state->get('list.filter') . '%'));
		}

		$query->where($db->quoteName('a.published') . ' = ' . $published);

		$query->order($db->quoteName($orderby) . ' ' . $orderDirection . ', a.title ASC');

		return $query;
	}
}
PK�|!]gg�&}}&views/tags/tmpl/default_batch_body.phpnu&1i�<?php
/**
 * @package     Joomla.Administrator
 * @subpackage  com_tags
 *
 * @copyright   (C) 2015 Open Source Matters, Inc. <https://www.joomla.org>
 * @license     GNU General Public License version 2 or later; see LICENSE.txt
 */
defined('_JEXEC') or die;
$published = $this->state->get('filter.published');
?>

<div class="container-fluid">
	<div class="row-fluid">
		<div class="control-group span6">
			<div class="controls">
				<?php echo JHtml::_('batch.language'); ?>
			</div>
		</div>
		<div class="control-group span6">
			<div class="controls">
				<?php echo JHtml::_('batch.access'); ?>
			</div>
		</div>
	</div>
</div>PK�|!]�ooviews/tags/tmpl/default.phpnu&1i�<?php
/**
 * @package     Joomla.Site
 * @subpackage  com_tags
 *
 * @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;

// Note that there are certain parts of this layout used only when there is exactly one tag.

JHtml::addIncludePath(JPATH_COMPONENT . '/helpers');
$description      = $this->params->get('all_tags_description');
$descriptionImage = $this->params->get('all_tags_description_image');

?>
<div class="tag-category<?php echo $this->pageclass_sfx; ?>">
	<?php if ($this->params->get('show_page_heading')) : ?>
		<h1>
			<?php echo $this->escape($this->params->get('page_heading')); ?>
		</h1>
	<?php endif; ?>
	<?php if ($this->params->get('all_tags_show_description_image') && !empty($descriptionImage)) : ?>
		<div>
			<img src="<?php echo htmlspecialchars($descriptionImage, ENT_QUOTES, 'UTF-8'); ?>" />
		</div>
	<?php endif; ?>
	<?php if (!empty($description)) : ?>
		<div>
			<?php echo $description; ?>
		</div>
	<?php endif; ?>
	<?php echo $this->loadTemplate('items'); ?>
</div>
PK�|!]�䁴�(views/tags/tmpl/default_batch_footer.phpnu&1i�<?php
/**
 * @package     Joomla.Administrator
 * @subpackage  com_tags
 *
 * @copyright   (C) 2015 Open Source Matters, Inc. <https://www.joomla.org>
 * @license     GNU General Public License version 2 or later; see LICENSE.txt
 */
defined('_JEXEC') or die;

?>
<button type="button" class="btn" onclick="document.getElementById('batch-tag-id').value='';document.getElementById('batch-access').value='';document.getElementById('batch-language-id').value=''" data-dismiss="modal">
	<?php echo JText::_('JCANCEL'); ?>
</button>
<button type="submit" class="btn btn-success" onclick="Joomla.submitbutton('tag.batch');return false;">
	<?php echo JText::_('JGLOBAL_BATCH_PROCESS'); ?>
</button>
PK�|!]�΄aaviews/tags/tmpl/default.xmlnu&1i�<?xml version="1.0" encoding="utf-8"?>
<metadata>
	<layout title="COM_TAGS_TAGS_VIEW_DEFAULT_TITLE" option="COM_TAGS_TAG_VIEW_DEFAULT_OPTION">
		<help
			key="JHELP_MENUS_MENU_ITEM_TAGS_ITEMS_LIST_ALL"
		/>
		<message>
			<![CDATA[COM_TAGS_TAGS_VIEW_DEFAULT_DESC]]>
		</message>
	</layout>
	<!-- Add fields to the request variables for the layout. -->
	<fields name="request">
		<fieldset name="request">

			<field
				name="parent_id"
				type="tag"
				label="COM_TAGS_FIELD_PARENT_TAG_LABEL"
				description="COM_TAGS_FIELD_PARENT_TAG_DESC"
				mode="nested"
				>
				<option value="">JNONE</option>
				<option value="1">JGLOBAL_ROOT</option>
			</field>

			<field
				name="tag_list_language_filter"
				type="contentlanguage"
				label="COM_TAGS_FIELD_LANGUAGE_FILTER_LABEL"
				description="COM_TAGS_FIELD_LANGUAGE_FILTER_DESC"
				default=""
				useglobal="true"
				>
				<option value="all">JALL</option>
				<option value="current_language">JCURRENT</option>
			</field>

		</fieldset>
	</fields>
	<!-- Add fields to the parameters object for the layout. -->
	<fields name="params">
		<fieldset name="basic">

			<field
				name="tag_columns"
				type="number"
				label="COM_TAGS_COMPACT_COLUMNS_LABEL"
				description="COM_TAGS_NUMBER_COLUMNS_DESC"
				default="4"
				filter="integer"
			/>

			<field
				name="all_tags_description"
				type="textarea"
				label="COM_TAGS_SHOW_ALL_TAGS_DESCRIPTION_LABEL"
				description="COM_TAGS_ALL_TAGS_DESCRIPTION_DESC"
				class="inputbox"
				rows="3"
				cols="30"
				filter="safehtml"
			/>

			<field
				name="all_tags_show_description_image"
				type="list"
				label="COM_TAGS_SHOW_ALL_TAGS_IMAGE_LABEL"
				description="COM_TAGS_SHOW_ALL_TAGS_IMAGE_DESC"
				class="chzn-color"
				>
				<option value="">JGLOBAL_USE_GLOBAL</option>
				<option value="0">JHIDE</option>
				<option value="1">JSHOW</option>
			</field>

			<field
				name="all_tags_description_image"
				type="media"
				label="COM_TAGS_ALL_TAGS_MEDIA_LABEL"
				description="COM_TAGS_ALL_TAGS_MEDIA_DESC"
			/>

			<field
				name="all_tags_orderby"
				type="list"
				label="JGLOBAL_FIELD_FIELD_ORDERING_LABEL"
				description="JGLOBAL_FIELD_FIELD_ORDERING_DESC"
				useglobal="true"
				>
				<option value="title">JGLOBAL_TITLE</option>
				<option value="hits">JGLOBAL_HITS</option>
				<option value="created_time">JGLOBAL_CREATED_DATE</option>
				<option value="modified_time">JGLOBAL_MODIFIED_DATE</option>
				<option value="publish_up">JGLOBAL_PUBLISHED_DATE</option>
			</field>

			<field
				name="all_tags_orderby_direction"
				type="list"
				label="JGLOBAL_ORDER_DIRECTION_LABEL"
				description="JGLOBAL_ORDER_DIRECTION_DESC"
				useglobal="true"
				>
				<option value="ASC">JGLOBAL_ORDER_ASCENDING</option>
				<option value="DESC">JGLOBAL_ORDER_DESCENDING</option>
			</field>

			<field
				name="all_tags_show_tag_image"
				type="list"
				label="COM_TAGS_SHOW_ITEM_IMAGE_LABEL"
				description="COM_TAGS_SHOW_ITEM_IMAGE_DESC"
				useglobal="true"
				class="chzn-color"
				>
				<option value="0">JHIDE</option>
				<option value="1">JSHOW</option>
			</field>

			<field
				name="all_tags_show_tag_description"
				type="list"
				label="COM_TAGS_SHOW_ITEM_DESCRIPTION_LABEL"
				description="COM_TAGS_SHOW_ITEM_DESCRIPTION_DESC"
				class="chzn-color"
				>
				<option value="">JGLOBAL_USE_GLOBAL</option>
				<option value="0">JHIDE</option>
				<option value="1">JSHOW</option>
			</field>

			<field
				name="all_tags_tag_maximum_characters"
				type="number"
				label="COM_TAGS_LIST_MAX_CHARACTERS_LABEL"
				description="COM_TAGS_LIST_MAX_CHARACTERS_DESC"
				filter="integer"
			/>

			<field
				name="all_tags_show_tag_hits"
				type="list"
				label="JGLOBAL_HITS"
				description="COM_TAGS_FIELD_CONFIG_HITS_DESC"
				useglobal="true"
				class="chzn-color"
				>
				<option value="0">JHIDE</option>
				<option value="1">JSHOW</option>
			</field>

		</fieldset>
		<fieldset
			name="selection"
			label="COM_TAGS_LIST_ALL_SELECTION_OPTIONS">

			<field
				name="maximum"
				type="number"
				label="COM_TAGS_LIST_MAX_LABEL"
				description="COM_TAGS_LIST_MAX_DESC"
				default="200"
				filter="integer"
			/>

			<field
				name="filter_field"
				type="list"
				label="JGLOBAL_FILTER_FIELD_LABEL"
				description="JGLOBAL_FILTER_FIELD_DESC"
				default=""
				useglobal="true"
				class="chzn-color"
				>
				<option value="0">JHIDE</option>
				<option value="1">JSHOW</option>
			</field>

			<field
				name="show_pagination_limit"
				type="list"
				label="JGLOBAL_DISPLAY_SELECT_LABEL"
				description="JGLOBAL_DISPLAY_SELECT_DESC"
				useglobal="true"
				class="chzn-color"
				>
				<option value="0">JHIDE</option>
				<option value="1">JSHOW</option>
			</field>

			<field
				name="show_pagination"
				type="list"
				label="JGLOBAL_PAGINATION_LABEL"
				description="JGLOBAL_PAGINATION_DESC"
				useglobal="true"
				class="chzn-color"
				>
				<option value="0">JHIDE</option>
				<option value="1">JSHOW</option>
				<option value="2">JGLOBAL_AUTO</option>
			</field>

			<field
				name="show_pagination_results"
				type="list"
				label="JGLOBAL_PAGINATION_RESULTS_LABEL"
				description="JGLOBAL_PAGINATION_RESULTS_DESC"
				useglobal="true"
				class="chzn-color"
				>
				<option value="0">JHIDE</option>
				<option value="1">JSHOW</option>
			</field>

		</fieldset>
		<fieldset name="integration">
			<field
				name="show_feed_link"
				type="list"
				label="JGLOBAL_SHOW_FEED_LINK_LABEL"
				description="JGLOBAL_SHOW_FEED_LINK_DESC"
				useglobal="true"
				class="chzn-color"
				>
				<option value="0">JHIDE</option>
				<option value="1">JSHOW</option>
			</field>

		</fieldset>
	</fields>
</metadata>
PK�|!]���}��views/tags/view.html.phpnu&1i�<?php
/**
 * @package     Joomla.Site
 * @subpackage  com_tags
 *
 * @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;

use Joomla\Registry\Registry;

/**
 * HTML View class for the Tags component
 *
 * @since  3.1
 */
class TagsViewTags extends JViewLegacy
{
	protected $state;

	protected $items;

	protected $item;

	protected $pagination;

	protected $params;

	/**
	 * 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)
	{
		// Get some data from the models
		$this->state      = $this->get('State');
		$this->items      = $this->get('Items');
		$this->pagination = $this->get('Pagination');
		$this->params = $this->state->get('params');
		$this->user   = JFactory::getUser();

		// Flag indicates to not add limitstart=0 to URL
		$this->pagination->hideEmptyLimitstart = true;

		/*
		 * // Change to catch
		 * if (count($errors = $this->get('Errors'))) {
		 * JError::raiseError(500, implode("\n", $errors));
		 * return false;
		 */

		// Check whether access level allows access.
		// @todo: Should already be computed in $item->params->get('access-view')
		$groups = $this->user->getAuthorisedViewLevels();

		if (!empty($this->items))
		{
			foreach ($this->items as $itemElement)
			{
				if (!in_array($itemElement->access, $groups))
				{
					unset($itemElement);
				}

				// Prepare the data.
				$temp = new Registry($itemElement->params);
				$itemElement->params = clone $this->params;
				$itemElement->params->merge($temp);
				$itemElement->params = (array) json_decode($itemElement->params);
			}
		}

		// Escape strings for HTML output
		$this->pageclass_sfx = htmlspecialchars($this->params->get('pageclass_sfx', ''));

		$active = JFactory::getApplication()->getMenu()->getActive();

		// Load layout from active query (in case it is an alternative menu item)
		if ($active && isset($active->query['option']) && $active->query['option'] === 'com_tags' && $active->query['view'] === 'tags')
		{
			if (isset($active->query['layout']))
			{
				$this->setLayout($active->query['layout']);
			}
		}
		else
		{
			// Load default All Tags layout from component
			if ($layout = $this->params->get('tags_layout'))
			{
				$this->setLayout($layout);
			}
		}

		$this->_prepareDocument();

		parent::display($tpl);
	}

	/**
	 * Prepares the document
	 *
	 * @return void
	 */
	protected function _prepareDocument()
	{
		$app   = JFactory::getApplication();
		$menus = $app->getMenu();
		$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::_('COM_TAGS_DEFAULT_PAGE_TITLE'));
		}

		if ($menu && (!isset($menu->query['option']) || $menu->query['option'] !== 'com_tags'))
		{
			$this->params->set('page_subheading', $menu->title);
		}

		// Set metadata for all tags menu item
		if ($this->params->get('menu-meta_description'))
		{
			$this->document->setDescription($this->params->get('menu-meta_description'));
		}

		if ($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 this is not a single tag menu item, set the page title to the tag titles
		$title = '';

		if (!empty($this->item))
		{
			foreach ($this->item as $i => $itemElement)
			{
				if ($itemElement->title)
				{
					if ($i != 0)
					{
						$title .= ', ';
					}

					$title .= $itemElement->title;
				}
			}

			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'));
			}

			$this->document->setTitle($title);

			foreach ($this->item as $itemElement)
			{
				if ($itemElement->metadesc)
				{
					$this->document->setDescription($this->item->metadesc);
				}
				elseif ($this->params->get('menu-meta_description'))
				{
					$this->document->setDescription($this->params->get('menu-meta_description'));
				}

				if ($itemElement->metakey)
				{
					$this->document->setMetadata('keywords', $this->tag->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')
				{
					$this->document->setMetaData('author', $itemElement->created_user_id);
				}

				$mdata = $this->item->metadata->toArray();

				foreach ($mdata as $k => $v)
				{
					if ($v)
					{
						$this->document->setMetadata($k, $v);
					}
				}
			}
		}

		// Respect configuration Sitename Before/After for TITLE in views All Tags.
		if (!$title && ($pos = $app->get('sitename_pagetitles', 0)))
		{
			$title = $this->document->getTitle();

			if ($pos == 1)
			{
				$title = JText::sprintf('JPAGETITLE', $app->get('sitename'), $title);
			}
			else
			{
				$title = JText::sprintf('JPAGETITLE', $title, $app->get('sitename'));
			}

			$this->document->setTitle($title);
		}

		// Add alternative feed link
		if ($this->params->get('show_feed_link', 1) == 1)
		{
			$link    = '&format=feed&limitstart=';
			$attribs = array('type' => 'application/rss+xml', 'title' => 'RSS 2.0');
			$this->document->addHeadLink(JRoute::_($link . '&type=rss'), 'alternate', 'rel', $attribs);
			$attribs = array('type' => 'application/atom+xml', 'title' => 'Atom 1.0');
			$this->document->addHeadLink(JRoute::_($link . '&type=atom'), 'alternate', 'rel', $attribs);
		}
	}
}
PK�|!]	Rn��views/tag/tmpl/edit.phpnu&1i�<?php
/**
 * @package     Joomla.Administrator
 * @subpackage  com_tags
 *
 * @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::_('behavior.formvalidator');
JHtml::_('behavior.keepalive');
JHtml::_('formbehavior.chosen', 'select');

JFactory::getDocument()->addScriptDeclaration("
	Joomla.submitbutton = function(task)
	{
		if (task == 'tag.cancel' || document.formvalidator.isValid(document.getElementById('item-form'))) {
			" . $this->form->getField('description')->save() . "
			Joomla.submitform(task, document.getElementById('item-form'));
		}
	};
");

// Fieldsets to not automatically render by /layouts/joomla/edit/params.php
$this->ignore_fieldsets = array('jmetadata');
?>

<form action="<?php echo JRoute::_('index.php?option=com_tags&layout=edit&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' => 'details')); ?>

		<?php echo JHtml::_('bootstrap.addTab', 'myTab', 'details', JText::_('COM_TAGS_FIELDSET_DETAILS')); ?>
		<div class="row-fluid">
			<div class="span9">
				<div class="form-vertical">
					<?php echo $this->form->renderField('description'); ?>
				</div>
			</div>
			<div class="span3">
				<?php echo JLayoutHelper::render('joomla.edit.global', $this); ?>
			</div>
		</div>
		<?php echo JHtml::_('bootstrap.endTab'); ?>

		<?php echo JLayoutHelper::render('joomla.edit.params', $this); ?>

		<?php echo JHtml::_('bootstrap.addTab', 'myTab', 'publishing', JText::_('JGLOBAL_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 echo JHtml::_('bootstrap.endTabSet'); ?>
	</div>
	<input type="hidden" name="task" value="" />
	<?php echo JHtml::_('form.token'); ?>
</form>
PK�|!]��`B__ views/tag/tmpl/edit_metadata.phpnu&1i�<?php
/**
 * @package     Joomla.Administrator
 * @subpackage  com_tags
 *
 * @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;
?>
<div class="control-group">
	<?php echo $this->form->getLabel('metadesc'); ?>
	<div class="controls">
		<?php echo $this->form->getInput('metadesc'); ?>
	</div>
</div>
<div class="control-group">
	<?php echo $this->form->getLabel('metakey'); ?>
	<div class="controls">
		<?php echo $this->form->getInput('metakey'); ?>
	</div>
</div>
<?php foreach ($this->form->getGroup('metadata') as $field) : ?>
<div class="control-group">
	<?php if (!$field->hidden) : ?>
		<?php echo $field->label; ?>
	<?php endif; ?>
	<div class="controls">
		<?php echo $field->input; ?>
	</div>
</div>
<?php endforeach; ?>
PK�|!]t�U��views/tag/tmpl/edit_options.phpnu&1i�<?php
/**
 * @package     Joomla.Administrator
 * @subpackage  com_tags
 *
 * @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;
?>
<?php
	echo JHtml::_('bootstrap.startAccordion', 'categoryOptions', array('active' => 'collapse0'));
	$fieldSets = $this->form->getFieldsets('params');
	$i = 0;

	foreach ($fieldSets as $name => $fieldSet) :
		$label = !empty($fieldSet->label) ? $fieldSet->label : 'COM_TAGS_' . $name . '_FIELDSET_LABEL';
		echo JHtml::_('bootstrap.addSlide', 'categoryOptions', JText::_($label), 'collapse' . ($i++));
			if (isset($fieldSet->description) && trim($fieldSet->description)) :
				echo '<p class="tip">' . $this->escape(JText::_($fieldSet->description)) . '</p>';
			endif;
			?>
				<?php foreach ($this->form->getFieldset($name) as $field) : ?>
					<div class="control-group">
						<div class="control-label">
							<?php echo $field->label; ?>
						</div>
						<div class="controls">
							<?php echo $field->input; ?>
						</div>
					</div>
				<?php endforeach; ?>

				<?php if ($name == 'basic') : ?>
					<div class="control-group">
						<div class="control-label">
							<?php echo $this->form->getLabel('note'); ?>
						</div>
						<div class="controls">
							<?php echo $this->form->getInput('note'); ?>
						</div>
					</div>
					<div class="control-group">
						<div class="control-label">
							<?php echo $this->form->getLabel('tag_layout'); ?>
						</div>
						<div class="controls">
							<?php echo $this->form->getInput('tag_layout'); ?>
						</div>
					</div>
					<div class="control-group">
						<div class="control-label">
							<?php echo $this->form->getLabel('tag_link_class'); ?>
						</div>
						<div class="controls">
							<?php echo $this->form->getInput('tag_link_class'); ?>
						</div>
					</div>
				<?php endif;
		echo JHtml::_('bootstrap.endSlide');
	endforeach;
echo JHtml::_('bootstrap.endAccordion');
PK�|!]W-}�+&+&views/tag/view.html.phpnu&1i�<?php
/**
 * @package     Joomla.Site
 * @subpackage  com_tags
 *
 * @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;

use Joomla\Registry\Registry;

/**
 * HTML View class for the Tags component
 *
 * @since  3.1
 */
class TagsViewTag extends JViewLegacy
{
	/**
	 * The model state
	 *
	 * @var    \Joomla\Registry\Registry
	 * @since  3.1
	 */
	protected $state;

	/**
	 * An array of items.
	 *
	 * @var    array
	 * @since  3.1
	 */
	protected $items;

	/**
	 * The active JObject (on success, false on failure)
	 *
	 * @var    JObject|boolean
	 * @since  3.1
	 */
	protected $item;

	/**
	 * Array of Children objects
	 *
	 * @var    array
	 * @since  3.1
	 */
	protected $children;

	/**
	 * The pagination object.
	 *
	 * @var    JPagination
	 * @since  3.1
	 */
	protected $pagination;

	/**
	 * The application parameters
	 *
	 * @var    \Joomla\Registry\Registry  The parameters object
	 * @since  3.1
	 */
	protected $params;

	/**
	 * Array of tags title
	 *
	 * @var    array
	 * @since  3.1
	 */
	protected $tags_title;

	/**
	 * 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.
	 *
	 * @since   3.1
	 */
	public function display($tpl = null)
	{
		$app    = JFactory::getApplication();
		$params = $app->getParams();

		// Get some data from the models
		$state      = $this->get('State');
		$items      = $this->get('Items');
		$item       = $this->get('Item');
		$children   = $this->get('Children');
		$parent     = $this->get('Parent');
		$pagination = $this->get('Pagination');

		// Flag indicates to not add limitstart=0 to URL
		$pagination->hideEmptyLimitstart = true;

		// Check whether access level allows access.
		// @TODO: Should already be computed in $item->params->get('access-view')
		$user   = JFactory::getUser();
		$groups = $user->getAuthorisedViewLevels();

		foreach ($item as $itemElement)
		{
			if (!in_array($itemElement->access, $groups))
			{
				unset($itemElement);
			}

			// Prepare the data.
			if (!empty($itemElement))
			{
				$temp = new Registry($itemElement->params);
				$itemElement->params   = clone $params;
				$itemElement->params->merge($temp);
				$itemElement->params   = (array) json_decode($itemElement->params);
				$itemElement->metadata = new Registry($itemElement->metadata);
			}
		}

		if ($items !== false)
		{
			JPluginHelper::importPlugin('content');

			foreach ($items as $itemElement)
			{
				$itemElement->event = new stdClass;

				// For some plugins.
				!empty($itemElement->core_body) ? $itemElement->text = $itemElement->core_body : $itemElement->text = null;

				$itemElement->core_params = new Registry($itemElement->core_params);

				$dispatcher = JEventDispatcher::getInstance();

				$dispatcher->trigger('onContentPrepare', array ('com_tags.tag', &$itemElement, &$itemElement->core_params, 0));

				$results = $dispatcher->trigger('onContentAfterTitle', array('com_tags.tag', &$itemElement, &$itemElement->core_params, 0));
				$itemElement->event->afterDisplayTitle = trim(implode("\n", $results));

				$results = $dispatcher->trigger('onContentBeforeDisplay', array('com_tags.tag', &$itemElement, &$itemElement->core_params, 0));
				$itemElement->event->beforeDisplayContent = trim(implode("\n", $results));

				$results = $dispatcher->trigger('onContentAfterDisplay', array('com_tags.tag', &$itemElement, &$itemElement->core_params, 0));
				$itemElement->event->afterDisplayContent = trim(implode("\n", $results));

				// Write the results back into the body
				if (!empty($itemElement->core_body))
				{
					$itemElement->core_body = $itemElement->text;
				}

				// Categories store the images differently so lets re-map it so the display is correct
				if ($itemElement->type_alias === 'com_content.category')
				{
					$itemElement->core_images = json_encode(
						array(
							'image_intro' => $itemElement->core_params->get('image', ''),
							'image_intro_alt' => $itemElement->core_params->get('image_alt', '')
						)
					);
				}
			}
		}

		$this->state      = $state;
		$this->items      = $items;
		$this->children   = $children;
		$this->parent     = $parent;
		$this->pagination = $pagination;
		$this->user       = $user;
		$this->item       = $item;

		// Escape strings for HTML output
		$this->pageclass_sfx = htmlspecialchars($params->get('pageclass_sfx', ''));

		// Merge tag params. If this is single-tag view, menu params override tag params
		// Otherwise, article params override menu item params
		$this->params = $this->state->get('params');
		$active       = $app->getMenu()->getActive();
		$temp         = clone $this->params;

		// Convert item params to a Registry object
		$item[0]->params = new Registry($item[0]->params);

		// Check to see which parameters should take priority
		if ($active)
		{
			$currentLink = $active->link;

			// If the current view is the active item and a tag view for one tag, then the menu item params take priority
			if (strpos($currentLink, 'view=tag') && strpos($currentLink, '&id[0]=' . (string) $item[0]->id))
			{
				// $item[0]->params are the tag params, $temp are the menu item params
				// Merge so that the menu item params take priority
				$item[0]->params->merge($temp);

				// Load layout from active query (in case it is an alternative menu item)
				if (isset($active->query['layout']))
				{
					$this->setLayout($active->query['layout']);
				}
			}
			else
			{
				// Current menuitem is not a single tag view, so the tag params take priority.
				// Merge the menu item params with the tag params so that the tag params take priority
				$temp->merge($item[0]->params);
				$item[0]->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[0]->params->get('tag_layout'))
				{
					$this->setLayout($layout);
				}
			}
		}
		else
		{
			// Merge so that item params take priority
			$temp->merge($item[0]->params);
			$item[0]->params = $temp;

			// Check for alternative layouts (since we are not in a single-tag menu item)
			// Single-tag menu item layout takes priority over alt layout for an article
			if ($layout = $item[0]->params->get('tag_layout'))
			{
				$this->setLayout($layout);
			}
		}

		// Increment the hit counter
		$model = $this->getModel();
		$model->hit();

		$this->_prepareDocument();

		parent::display($tpl);
	}

	/**
	 * Prepares the document.
	 *
	 * @return  void
	 */
	protected function _prepareDocument()
	{
		$app              = JFactory::getApplication();
		$menu             = $app->getMenu()->getActive();
		$this->tags_title = $this->getTagsTitle();
		$pathway          = $app->getPathway();
		$title            = '';

		// Highest priority for "Browser Page Title".
		if ($menu)
		{
			$title = $menu->params->get('page_title', '');
		}

		if ($this->tags_title)
		{
			$this->params->def('page_heading', $this->tags_title);
			$title = $title ?: $this->tags_title;
		}
		elseif ($menu)
		{
			$this->params->def('page_heading', $this->params->get('page_title', $menu->title));
			$title = $title ?: $this->params->get('page_title', $menu->title);

			if (!isset($menu->query['option']) || $menu->query['option'] !== 'com_tags')
			{
				$this->params->set('page_subheading', $menu->title);
			}
		}

		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'));
		}

		$this->document->setTitle($title);

		$pathway->addItem($title);

		foreach ($this->item as $itemElement)
		{
			if ($itemElement->metadesc)
			{
				$this->document->setDescription($itemElement->metadesc);
			}
			elseif ($this->params->get('menu-meta_description'))
			{
				$this->document->setDescription($this->params->get('menu-meta_description'));
			}

			if ($itemElement->metakey)
			{
				$this->document->setMetadata('keywords', $itemElement->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 (count($this->item) === 1)
		{
			foreach ($this->item[0]->metadata->toArray() as $k => $v)
			{
				if ($v)
				{
					$this->document->setMetadata($k, $v);
				}
			}
		}

		if ($this->params->get('show_feed_link', 1) == 1)
		{
			$link    = '&format=feed&limitstart=';
			$attribs = array('type' => 'application/rss+xml', 'title' => 'RSS 2.0');
			$this->document->addHeadLink(JRoute::_($link . '&type=rss'), 'alternate', 'rel', $attribs);
			$attribs = array('type' => 'application/atom+xml', 'title' => 'Atom 1.0');
			$this->document->addHeadLink(JRoute::_($link . '&type=atom'), 'alternate', 'rel', $attribs);
		}
	}

	/**
	 * Creates the tags title for the output
	 *
	 * @return  boolean
	 */
	protected function getTagsTitle()
	{
		$tags_title = array();

		if (!empty($this->item))
		{
			$user   = JFactory::getUser();
			$groups = $user->getAuthorisedViewLevels();

			foreach ($this->item as $item)
			{
				if (in_array($item->access, $groups))
				{
					$tags_title[] = $item->title;
				}
			}
		}

		return implode(' ', $tags_title);
	}
}
PK
~!]҆b(��helpers/route.phpnu&1i�<?php
/**
 * @package     Joomla.Site
 * @subpackage  com_tags
 *
 * @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;

/**
 * Tags Component Route Helper.
 *
 * @since  3.1
 */
class TagsHelperRoute extends JHelperRoute
{
	protected static $lookup;

	/**
	 * Tries to load the router for the component and calls it. Otherwise uses getTagRoute.
	 *
	 * @param   integer  $contentItemId     Component item id
	 * @param   string   $contentItemAlias  Component item alias
	 * @param   integer  $contentCatId      Component item category id
	 * @param   string   $language          Component item language
	 * @param   string   $typeAlias         Component type alias
	 * @param   string   $routerName        Component router
	 *
	 * @return  string  URL link to pass to JRoute
	 *
	 * @since   3.1
	 */
	public static function getItemRoute($contentItemId, $contentItemAlias, $contentCatId, $language, $typeAlias, $routerName)
	{
		$link = '';
		$explodedAlias = explode('.', $typeAlias);
		$explodedRouter = explode('::', $routerName);

		if (file_exists($routerFile = JPATH_BASE . '/components/' . $explodedAlias[0] . '/helpers/route.php'))
		{
			JLoader::register($explodedRouter[0], $routerFile);
			$routerClass = $explodedRouter[0];
			$routerMethod = $explodedRouter[1];

			if (class_exists($routerClass) && method_exists($routerClass, $routerMethod))
			{
				if ($routerMethod === 'getCategoryRoute')
				{
					$link = $routerClass::$routerMethod($contentItemId, $language);
				}
				else
				{
					$link = $routerClass::$routerMethod($contentItemId . ':' . $contentItemAlias, $contentCatId, $language);
				}
			}
		}

		if ($link === '')
		{
			// Create a fallback link in case we can't find the component router
			$router = new JHelperRoute;
			$link = $router->getRoute($contentItemId, $typeAlias, $link, $language, $contentCatId);
		}

		return $link;
	}

	/**
	 * Tries to load the router for the component and calls it. Otherwise calls getRoute.
	 *
	 * @param   integer  $id  The ID of the tag
	 *
	 * @return  string  URL link to pass to JRoute
	 *
	 * @since   3.1
	 */
	public static function getTagRoute($id)
	{
		$needles = array(
			'tag'  => array((int) $id)
		);

		if ($id < 1)
		{
			$link = '';
		}
		else
		{
			$link = 'index.php?option=com_tags&view=tag&id=' . $id;

			if ($item = self::_findItem($needles))
			{
				$link .= '&Itemid=' . $item;
			}
			else
			{
				$needles = array('tags' => array(1, 0));

				if ($item = self::_findItem($needles))
				{
					$link .= '&Itemid=' . $item;
				}
			}
		}

		return $link;
	}

	/**
	 * Tries to load the router for the tags view.
	 *
	 * @return  string  URL link to pass to JRoute
	 *
	 * @since   3.7
	 */
	public static function getTagsRoute()
	{
		$needles = array(
			'tags'  => array(0)
		);

		$link = 'index.php?option=com_tags&view=tags';

		if ($item = self::_findItem($needles))
		{
			$link .= '&Itemid=' . $item;
		}

		return $link;
	}

	/**
	 * Find Item static function
	 *
	 * @param   array  $needles  Array used to get the language value
	 *
	 * @return null
	 *
	 * @throws Exception
	 */
	protected static function _findItem($needles = null)
	{
		$app      = JFactory::getApplication();
		$menus    = $app->getMenu('site');
		$language = isset($needles['language']) ? $needles['language'] : '*';

		// Prepare the reverse lookup array.
		if (self::$lookup === null)
		{
			self::$lookup = array();

			$component = JComponentHelper::getComponent('com_tags');
			$items     = $menus->getItems('component_id', $component->id);

			if ($items)
			{
				foreach ($items as $item)
				{
					if (isset($item->query, $item->query['view']))
					{
						$lang = ($item->language != '' ? $item->language : '*');

						if (!isset(self::$lookup[$lang]))
						{
							self::$lookup[$lang] = array();
						}

						$view = $item->query['view'];

						if (!isset(self::$lookup[$lang][$view]))
						{
							self::$lookup[$lang][$view] = array();
						}

						// Only match menu items that list one tag
						if (isset($item->query['id']) && is_array($item->query['id']))
						{
							foreach ($item->query['id'] as $position => $tagId)
							{
								if (!isset(self::$lookup[$lang][$view][$item->query['id'][$position]]) || count($item->query['id']) == 1)
								{
									self::$lookup[$lang][$view][$item->query['id'][$position]] = $item->id;
								}
							}
						}
						elseif ($view == 'tags')
						{
							self::$lookup[$lang]['tags'][] = $item->id;
						}
					}
				}
			}
		}

		if ($needles)
		{
			foreach ($needles as $view => $ids)
			{
				if (isset(self::$lookup[$language][$view]))
				{
					foreach ($ids as $id)
					{
						if (isset(self::$lookup[$language][$view][(int) $id]))
						{
							return self::$lookup[$language][$view][(int) $id];
						}
					}
				}
			}
		}
		else
		{
			$active = $menus->getActive();

			if ($active)
			{
				return $active->id;
			}
		}

		return null;
	}
}
PK
~!]�b�%

views/tag/view.feed.phpnu&1i�<?php
/**
 * @package     Joomla.Site
 * @subpackage  com_tags
 *
 * @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;

/**
 * HTML View class for the Tags component
 *
 * @since  3.1
 */
class TagsViewTag extends JViewLegacy
{
	/**
	 * 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();
		$document  = JFactory::getDocument();
		$ids       = (array) $app->input->get('id', array(), 'int');
		$i         = 0;
		$tagIds    = '';

		// Remove zero values resulting from input filter
		$ids = array_filter($ids);

		foreach ($ids as $id)
		{
			if ($i !== 0)
			{
				$tagIds .= '&';
			}

			$tagIds .= 'id[' . $i . ']=' . $id;

			$i++;
		}

		$document->link = JRoute::_('index.php?option=com_tags&view=tag&' . $tagIds);

		$app->input->set('limit', $app->get('feed_limit'));
		$siteEmail        = $app->get('mailfrom');
		$fromName         = $app->get('fromname');
		$feedEmail        = $app->get('feed_email', 'none');
		$document->editor = $fromName;

		if ($feedEmail !== 'none')
		{
			$document->editorEmail = $siteEmail;
		}

		// Get some data from the model
		$items    = $this->get('Items');

		if ($items !== false)
		{
			foreach ($items as $item)
			{
				// Strip HTML from feed item title
				$title = $this->escape($item->core_title);
				$title = html_entity_decode($title, ENT_COMPAT, 'UTF-8');

				// Strip HTML from feed item description text
				$description = $item->core_body;
				$author      = $item->core_created_by_alias ?: $item->author;
				$date        = ($item->displayDate ? date('r', strtotime($item->displayDate)) : '');

				// Load individual item creator class
				$feeditem              = new JFeedItem;
				$feeditem->title       = $title;
				$feeditem->link        = JRoute::_($item->link);
				$feeditem->description = $description;
				$feeditem->date        = $date;
				$feeditem->category    = $title;
				$feeditem->author      = $author;

				if ($feedEmail === 'site')
				{
					$item->authorEmail = $siteEmail;
				}
				elseif ($feedEmail === 'author')
				{
					$item->authorEmail = $item->author_email;
				}

				// Loads item info into RSS array
				$document->addItem($feeditem);
			}
		}
	}
}
PK
~!]I��s		views/tag/tmpl/default.xmlnu&1i�<?xml version="1.0" encoding="utf-8"?>
<metadata>
	<layout title="COM_TAGS_TAG_VIEW_DEFAULT_TITLE" option="COM_TAGS_TAG_VIEW_DEFAULT_OPTION">
		<help
			key="JHELP_MENUS_MENU_ITEM_TAGS_ITEMS_LIST"
		/>
		<message>
			<![CDATA[COM_TAGS_TAG_VIEW_DEFAULT_DESC]]>
		</message>
	</layout>

	<!-- Add fields to the request variables for the layout. -->
	<fields name="request">
		<fieldset name="request">

			<field
				name="id"
				type="tag"
				label="COM_TAGS_FIELD_TAG_LABEL"
				description="COM_TAGS_FIELD_SELECT_TAG_DESC"
				mode="nested"
				required="true"
				multiple="true"
			/>

			<field
				name="types"
				type="contenttype"
				label="COM_TAGS_FIELD_TYPE_LABEL"
				description="COM_TAGS_FIELD_TYPE_DESC"
				multiple="true"
			/>

			<field
				name="tag_list_language_filter"
				type="contentlanguage"
				label="COM_TAGS_FIELD_LANGUAGE_FILTER_LABEL"
				description="COM_TAGS_FIELD_LANGUAGE_FILTER_DESC"
				default=""
				useglobal="true"
				>
				<option value="all">JALL</option>
				<option value="current_language">JCURRENT</option>
			</field>

		</fieldset>
	</fields>

	<!-- Add fields to the parameters object for the layout. -->
<fields name="params">
	<fieldset name="basic" label="COM_TAGS_OPTIONS">

			<field
				name="show_tag_title"
				type="list"
				label="COM_TAGS_SHOW_TAG_TITLE_LABEL"
				description="COM_TAGS_SHOW_TAG_TITLE_DESC"
				useglobal="true"
				class="chzn-color"
				>
				<option value="0">JHIDE</option>
				<option value="1">JSHOW</option>
			</field>

			<field
				name="tag_list_show_tag_image"
				type="list"
				label="COM_TAGS_SHOW_TAG_IMAGE_LABEL"
				description="COM_TAGS_SHOW_TAG_IMAGE_DESC"
				useglobal="true"
				class="chzn-color"
				>
				<option value="0">JHIDE</option>
				<option value="1">JSHOW</option>
			</field>

			<field
				name="tag_list_show_tag_description"
				type="list"
				label="COM_TAGS_SHOW_TAG_DESCRIPTION_LABEL"
				description="COM_TAGS_SHOW_TAG_DESCRIPTION_DESC"
				useglobal="true"
				class="chzn-color"
				>
				<option value="0">JHIDE</option>
				<option value="1">JSHOW</option>
			</field>

			<field
				name="tag_list_image"
				type="media"
				label="COM_TAGS_TAG_LIST_MEDIA_LABEL"
				description="COM_TAGS_TAG_LIST_MEDIA_DESC"
			/>

			<field
				name="tag_list_description"
				type="textarea"
				class="inputbox"
				label="COM_TAGS_SHOW_TAG_LIST_DESCRIPTION_LABEL"
				description="COM_TAGS_TAG_LIST_DESCRIPTION_DESC"
				rows="3"
				cols="30"
				filter="safehtml"
			/>

			<field
				name="tag_list_orderby"
				type="list"
				label="JGLOBAL_FIELD_FIELD_ORDERING_LABEL"
				description="JGLOBAL_FIELD_FIELD_ORDERING_DESC"
				default=""
				useglobal="true"
				>
				<option value="c.core_title">JGLOBAL_TITLE</option>
				<option value="match_count">COM_TAGS_MATCH_COUNT</option>
				<option value="c.core_created_time">JGLOBAL_CREATED_DATE</option>
				<option value="c.core_modified_time">JGLOBAL_MODIFIED_DATE</option>
				<option value="c.core_publish_up">JGLOBAL_PUBLISHED_DATE</option>
			</field>

			<field
				name="tag_list_orderby_direction"
				type="list"
				label="JGLOBAL_ORDER_DIRECTION_LABEL"
				description="JGLOBAL_ORDER_DIRECTION_DESC"
				useglobal="true"
				>
				<option value="ASC">JGLOBAL_ORDER_ASCENDING</option>
				<option value="DESC">JGLOBAL_ORDER_DESCENDING</option>
			</field>

		</fieldset>

		<fieldset name="advanced" label="COM_TAGS_ITEM_OPTIONS">

			<field
				name="spacer2"
				type="spacer"
				label="COM_TAGS_SUBSLIDER_DRILL_TAG_LIST_LABEL"
				class="text"
			/>

			<field
				name="tag_list_show_item_image"
				type="list"
				label="COM_TAGS_TAG_LIST_SHOW_ITEM_IMAGE_LABEL"
				description="COM_TAGS_TAG_LIST_SHOW_ITEM_IMAGE_DESC"
				useglobal="true"
				class="chzn-color"
				>
				<option value="0">JHIDE</option>
				<option value="1">JSHOW</option>
			</field>

			<field
				name="tag_list_show_item_description"
				type="list"
				label="COM_TAGS_TAG_LIST_SHOW_ITEM_DESCRIPTION_LABEL"
				description="COM_TAGS_TAG_LIST_SHOW_ITEM_DESCRIPTION_DESC"
				useglobal="true"
				class="chzn-color"
				>
				<option value="0">JHIDE</option>
				<option value="1">JSHOW</option>
			</field>

			<field
				name="tag_list_item_maximum_characters"
				type="number"
				label="COM_TAGS_LIST_MAX_CHARACTERS_LABEL"
				description="COM_TAGS_LIST_MAX_CHARACTERS_DESC"
				filter="integer"
				useglobal="true"
			/>

			<field
				name="filter_field"
				type="list"
				label="JGLOBAL_FILTER_FIELD_LABEL"
				description="JGLOBAL_FILTER_FIELD_DESC"
				default=""
				useglobal="true"
				class="chzn-color"
				>
				<option value="0">JHIDE</option>
				<option value="1">JSHOW</option>
			</field>
		</fieldset>

		<fieldset name="pagination" label="COM_TAGS_PAGINATION_OPTIONS">

			<field
				name="show_pagination_limit"
				type="list"
				label="JGLOBAL_DISPLAY_SELECT_LABEL"
				description="JGLOBAL_DISPLAY_SELECT_DESC"
				useglobal="true"
				class="chzn-color"
				>
				<option value="0">JHIDE</option>
				<option value="1">JSHOW</option>
			</field>

			<field
				name="show_pagination"
				type="list"
				label="JGLOBAL_PAGINATION_LABEL"
				description="JGLOBAL_PAGINATION_DESC"
				useglobal="true"
				class="chzn-color"
				>
				<option value="0">JHIDE</option>
				<option value="1">JSHOW</option>
				<option value="2">JGLOBAL_AUTO</option>
			</field>

			<field
				name="show_pagination_results"
				type="list"
				label="JGLOBAL_PAGINATION_RESULTS_LABEL"
				description="JGLOBAL_PAGINATION_RESULTS_DESC"
				useglobal="true"
				class="chzn-color"
				>
				<option value="0">JHIDE</option>
				<option value="1">JSHOW</option>
			</field>

		</fieldset>

		<fieldset name="selection" label="COM_TAGS_LIST_SELECTION_OPTIONS">

			<field
				name="return_any_or_all"
				type="list"
				label="COM_TAGS_SEARCH_TYPE_LABEL"
				description="COM_TAGS_SEARCH_TYPE_DESC"
				useglobal="true"
				>
				<option value="0">COM_TAGS_ALL</option>
				<option value="1">COM_TAGS_ANY</option>
			</field>

			<field
				name="include_children"
				type="list"
				label="COM_TAGS_INCLUDE_CHILDREN_LABEL"
				description="COM_TAGS_INCLUDE_CHILDREN_DESC"
				default=""
				useglobal="true"
				>
				<option value="0">COM_TAGS_EXCLUDE</option>
				<option value="1">COM_TAGS_INCLUDE</option>
			</field>

		</fieldset>

		<fieldset name="integration">

			<field
				name="show_feed_link"
				type="list"
				label="JGLOBAL_SHOW_FEED_LINK_LABEL"
				description="JGLOBAL_SHOW_FEED_LINK_DESC"
				useglobal="true"
				class="chzn-color"
				>
				<option value="0">JHIDE</option>
				<option value="1">JSHOW</option>
			</field>

		</fieldset>
	</fields>
</metadata>
PK
~!]�?�__views/tag/tmpl/default.phpnu&1i�<?php
/**
 * @package     Joomla.Site
 * @subpackage  com_tags
 *
 * @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;

// Note that there are certain parts of this layout used only when there is exactly one tag.
JHtml::addIncludePath(JPATH_COMPONENT . '/helpers');
$isSingleTag = count($this->item) === 1;

?>
<div class="tag-category<?php echo $this->pageclass_sfx; ?>">
	<?php if ($this->params->get('show_page_heading')) : ?>
		<h1>
			<?php echo $this->escape($this->params->get('page_heading')); ?>
		</h1>
	<?php endif; ?>
	<?php if ($this->params->get('show_tag_title', 1)) : ?>
		<h2>
			<?php echo JHtml::_('content.prepare', $this->tags_title, '', 'com_tag.tag'); ?>
		</h2>
	<?php endif; ?>
	<?php // We only show a tag description if there is a single tag. ?>
	<?php if (count($this->item) === 1 && ($this->params->get('tag_list_show_tag_image', 1) || $this->params->get('tag_list_show_tag_description', 1))) : ?>
		<div class="category-desc">
			<?php $images = json_decode($this->item[0]->images); ?>
			<?php if ($this->params->get('tag_list_show_tag_image', 1) == 1 && !empty($images->image_fulltext)) : ?>
				<img src="<?php echo htmlspecialchars($images->image_fulltext, ENT_QUOTES, 'UTF-8'); ?>" alt="<?php echo htmlspecialchars($images->image_fulltext_alt, ENT_QUOTES, 'UTF-8'); ?>" />
			<?php endif; ?>
			<?php if ($this->params->get('tag_list_show_tag_description') == 1 && $this->item[0]->description) : ?>
				<?php echo JHtml::_('content.prepare', $this->item[0]->description, '', 'com_tags.tag'); ?>
			<?php endif; ?>
			<div class="clr"></div>
		</div>
	<?php endif; ?>
	<?php // If there are multiple tags and a description or image has been supplied use that. ?>
	<?php if ($this->params->get('tag_list_show_tag_description', 1) || $this->params->get('show_description_image', 1)) : ?>
		<?php if ($this->params->get('show_description_image', 1) == 1 && $this->params->get('tag_list_image')) : ?>
			<img src="<?php echo htmlspecialchars($this->params->get('tag_list_image'), ENT_QUOTES, 'UTF-8'); ?>" />
		<?php endif; ?>
		<?php if ($this->params->get('tag_list_description', '') > '') : ?>
			<?php echo JHtml::_('content.prepare', $this->params->get('tag_list_description'), '', 'com_tags.tag'); ?>
		<?php endif; ?>
	<?php endif; ?>
	<?php echo $this->loadTemplate('items'); ?>
	<?php if (($this->params->def('show_pagination', 1) == 1 || ($this->params->get('show_pagination') == 2)) && ($this->pagination->get('pages.total') > 1)) : ?>
		<div class="pagination">
			<?php if ($this->params->def('show_pagination_results', 1)) : ?>
				<p class="counter pull-right">
					<?php echo $this->pagination->getPagesCounter(); ?>
				</p>
			<?php endif; ?>
			<?php echo $this->pagination->getPagesLinks(); ?>
		</div>
	<?php endif; ?>
</div>
PK
~!]�&&views/tag/tmpl/list.xmlnu&1i�<?xml version="1.0" encoding="utf-8"?>
<metadata>
	<layout title="COM_TAGS_TAG_VIEW_LIST_COMPACT_TITLE" option="COM_TAGS_TAG_VIEW_LIST_COMPACT_OPTION">
		<help
			key="JHELP_MENUS_MENU_ITEM_TAGS_ITEMS_COMPACT_LIST"
		/>
		<message>
			<![CDATA[COM_TAGS_TAG_VIEW_LIST_DESC]]>
		</message>
	</layout>

	<!-- Add fields to the request variables for the layout. -->
	<fields name="request">
		<fieldset name="request">

			<field
				name="id"
				type="tag"
				label="COM_TAGS_FIELD_TAG_LABEL"
				description="COM_TAGS_FIELD_SELECT_TAG_DESC"
				mode="nested"
				required="true"
				multiple="true"
			/>

			<field
				name="types"
				type="contenttype"
				label="COM_TAGS_FIELD_TYPE_LABEL"
				description="COM_TAGS_FIELD_TYPE_DESC"
				multiple="true"
			/>

			<field
				name="tag_list_language_filter"
				type="contentlanguage"
				label="COM_TAGS_FIELD_LANGUAGE_FILTER_LABEL"
				description="COM_TAGS_FIELD_LANGUAGE_FILTER_DESC"
				default=""
				useglobal="true"
				>
				<option value="all">JALL</option>
				<option value="current_language">JCURRENT</option>
			</field>

		</fieldset>
	</fields>
	<!-- Add fields to the parameters object for the layout. -->
	<fields name="params">
		<fieldset name="basic" label="COM_TAGS_OPTIONS">

			<field
				name="show_tag_title"
				type="list"
				label="COM_TAGS_SHOW_TAG_TITLE_LABEL"
				description="COM_TAGS_SHOW_TAG_TITLE_DESC"
				useglobal="true"
				class="chzn-color"
				>
				<option value="0">JHIDE</option>
				<option value="1">JSHOW</option>
			</field>

			<field
				name="tag_list_show_tag_image"
				type="list"
				label="COM_TAGS_SHOW_TAG_IMAGE_LABEL"
				description="COM_TAGS_SHOW_TAG_IMAGE_DESC"
				useglobal="true"
				class="chzn-color"
				>
				<option value="0">JHIDE</option>
				<option value="1">JSHOW</option>
			</field>

			<field
				name="tag_list_show_tag_description"
				type="list"
				label="COM_TAGS_SHOW_TAG_DESCRIPTION_LABEL"
				description="COM_TAGS_SHOW_TAG_DESCRIPTION_DESC"
				useglobal="true"
				class="chzn-color"
				>
				<option value="0">JHIDE</option>
				<option value="1">JSHOW</option>
			</field>

			<field
				name="tag_list_image"
				type="media"
				label="COM_TAGS_TAG_LIST_MEDIA_LABEL"
				description="COM_TAGS_TAG_LIST_MEDIA_DESC"
			/>

			<field
				name="tag_list_description"
				type="textarea"
				label="COM_TAGS_SHOW_TAG_LIST_DESCRIPTION_LABEL"
				description="COM_TAGS_TAG_LIST_DESCRIPTION_DESC"
				class="inputbox"
				rows="3"
				cols="30"
				filter="safehtml"
			/>

			<field
				name="tag_list_orderby"
				type="list"
				label="JGLOBAL_FIELD_FIELD_ORDERING_LABEL"
				description="JGLOBAL_FIELD_FIELD_ORDERING_DESC"
				default=""
				useglobal="true"
				>
				<option value="c.core_title">JGLOBAL_TITLE</option>
				<option value="match_count">COM_TAGS_MATCH_COUNT</option>
				<option value="c.core_created_time">JGLOBAL_CREATED_DATE</option>
				<option value="c.core_modified_time">JGLOBAL_MODIFIED_DATE</option>
				<option value="c.core_publish_up">JGLOBAL_PUBLISHED_DATE</option>
			</field>

			<field
				name="tag_list_orderby_direction"
				type="list"
				label="JGLOBAL_ORDER_DIRECTION_LABEL"
				description="JGLOBAL_ORDER_DIRECTION_DESC"
				useglobal="true"
				>
				<option value="ASC">JGLOBAL_ORDER_ASCENDING</option>
				<option value="DESC">JGLOBAL_ORDER_DESCENDING</option>
			</field>

		</fieldset>

		<fieldset name="advanced" label="JGLOBAL_LIST_LAYOUT_OPTIONS">

			<field
				name="spacer2"
				type="spacer"
				label="COM_TAGS_SUBSLIDER_DRILL_TAG_LIST_LABEL"
				class="text"
			/>

			<field
				name="tag_list_show_item_image"
				type="list"
				label="COM_TAGS_TAG_LIST_SHOW_ITEM_IMAGE_LABEL"
				description="COM_TAGS_TAG_LIST_SHOW_ITEM_IMAGE_DESC"
				useglobal="true"
				class="chzn-color"
				>
				<option value="0">JHIDE</option>
				<option value="1">JSHOW</option>
			</field>

			<field
				name="tag_list_show_item_description"
				type="list"
				label="COM_TAGS_TAG_LIST_SHOW_ITEM_DESCRIPTION_LABEL"
				description="COM_TAGS_TAG_LIST_SHOW_ITEM_DESCRIPTION_DESC"
				useglobal="true"
				class="chzn-color"
				>
				<option value="0">JHIDE</option>
				<option value="1">JSHOW</option>
			</field>

			<field
				name="tag_list_item_maximum_characters"
				type="number"
				label="COM_TAGS_LIST_MAX_CHARACTERS_LABEL"
				description="COM_TAGS_LIST_MAX_CHARACTERS_DESC"
				filter="integer"
				useglobal="true"
			/>

			<field
				name="filter_field"
				type="list"
				label="JGLOBAL_FILTER_FIELD_LABEL"
				description="JGLOBAL_FILTER_FIELD_DESC"
				default=""
				useglobal="true"
				class="chzn-color"
				>
				<option value="0">JHIDE</option>
				<option value="1">JSHOW</option>
			</field>

			<field
				name="show_pagination_limit"
				type="list"
				label="JGLOBAL_DISPLAY_SELECT_LABEL"
				description="JGLOBAL_DISPLAY_SELECT_DESC"
				useglobal="true"
				class="chzn-color"
				>
				<option value="0">JHIDE</option>
				<option value="1">JSHOW</option>
			</field>

			<field
				name="display_num"
				type="list"
				label="COM_TAGS_FIELD_NUMBER_ITEMS_LIST_LABEL"
				description="COM_TAGS_FIELD_NUMBER_ITEMS_LIST_DESC"
				class="chzn-color"
				>
				<option value="">JGLOBAL_USE_GLOBAL</option>
				<option value="5">J5</option>
				<option value="10">J10</option>
				<option value="15">J15</option>
				<option value="20">J20</option>
				<option value="25">J25</option>
				<option value="30">J30</option>
				<option value="50">J50</option>
				<option value="100">J100</option>
				<option value="0">JALL</option>
			</field>

			<field
				name="show_pagination"
				type="list"
				label="JGLOBAL_PAGINATION_LABEL"
				description="JGLOBAL_PAGINATION_DESC"
				useglobal="true"
				class="chzn-color"
				>
				<option value="0">JHIDE</option>
				<option value="1">JSHOW</option>
				<option value="2">JGLOBAL_AUTO</option>
			</field>

			<field
				name="show_pagination_results"
				type="list"
				label="JGLOBAL_PAGINATION_RESULTS_LABEL"
				description="JGLOBAL_PAGINATION_RESULTS_DESC"
				useglobal="true"
				class="chzn-color"
				>
				<option value="0">JHIDE</option>
				<option value="1">JSHOW</option>
			</field>

			<field
				name="tag_list_show_date"
				type="list"
				label="JGLOBAL_SHOW_DATE_LABEL"
				description="JGLOBAL_SHOW_DATE_DESC"
				useglobal="true"
				class="chzn-color"
				>
				<option value="0">JHIDE</option>
				<option value="created">JGLOBAL_CREATED</option>
				<option value="modified">JGLOBAL_MODIFIED</option>
				<option value="published">JPUBLISHED</option>
			</field>

			<field
				name="date_format"
				type="text"
				label="JGLOBAL_DATE_FORMAT_LABEL"
				description="JGLOBAL_DATE_FORMAT_DESC"
				size="15"
			/>

		</fieldset>

		<fieldset name="selection" label="COM_TAGS_LIST_SELECTION_OPTIONS">

			<field
				name="return_any_or_all"
				type="list"
				label="COM_TAGS_SEARCH_TYPE_LABEL"
				description="COM_TAGS_SEARCH_TYPE_DESC"
				useglobal="true"
				>
				<option value="0">COM_TAGS_ALL</option>
				<option value="1">COM_TAGS_ANY</option>
			</field>

			<field
				name="include_children"
				type="list"
				label="COM_TAGS_INCLUDE_CHILDREN_LABEL"
				description="COM_TAGS_INCLUDE_CHILDREN_DESC"
				default=""
				useglobal="true"
				>
				<option value="0">COM_TAGS_EXCLUDE</option>
				<option value="1">COM_TAGS_INCLUDE</option>
			</field>

		</fieldset>

		<fieldset name="integration">

			<field
				name="show_feed_link"
				type="list"
				label="JGLOBAL_SHOW_FEED_LINK_LABEL"
				description="JGLOBAL_SHOW_FEED_LINK_DESC"
				useglobal="true"
				class="chzn-color"
				>
				<option value="0">JHIDE</option>
				<option value="1">JSHOW</option>
			</field>

		</fieldset>
	</fields>
</metadata>
PK
~!]\�5�/	/	views/tag/tmpl/list.phpnu&1i�<?php
/**
 * @package     Joomla.Site
 * @subpackage  com_tags
 *
 * @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;

// Note that there are certain parts of this layout used only when there is exactly one tag.

JHtml::addIncludePath(JPATH_COMPONENT . '/helpers');
$n = count($this->items);

?>
<div class="tag-category<?php echo $this->pageclass_sfx; ?>">
	<?php if ($this->params->get('show_page_heading')) : ?>
		<h1>
			<?php echo $this->escape($this->params->get('page_heading')); ?>
		</h1>
	<?php endif; ?>
	<?php if ($this->params->get('show_tag_title', 1)) : ?>
		<h2>
			<?php echo JHtml::_('content.prepare', $this->tags_title, '', 'com_tag.tag'); ?>
		</h2>
	<?php endif; ?>
	<?php // We only show a tag description if there is a single tag. ?>
	<?php if (count($this->item) === 1 && ($this->params->get('tag_list_show_tag_image', 1) || $this->params->get('tag_list_show_tag_description', 1))) : ?>
		<div class="category-desc">
			<?php $images = json_decode($this->item[0]->images); ?>
			<?php if ($this->params->get('tag_list_show_tag_image', 1) == 1 && !empty($images->image_fulltext)) : ?>
				<img src="<?php echo htmlspecialchars($images->image_fulltext, ENT_QUOTES, 'UTF-8'); ?>">
			<?php endif; ?>
			<?php if ($this->params->get('tag_list_show_tag_description') == 1 && $this->item[0]->description) : ?>
				<?php echo JHtml::_('content.prepare', $this->item[0]->description, '', 'com_tags.tag'); ?>
			<?php endif; ?>
			<div class="clr"></div>
		</div>
	<?php endif; ?>
	<?php // If there are multiple tags and a description or image has been supplied use that. ?>
	<?php if ($this->params->get('tag_list_show_tag_description', 1) || $this->params->get('show_description_image', 1)) : ?>
		<?php if ($this->params->get('show_description_image', 1) == 1 && $this->params->get('tag_list_image')) : ?>
			<img src="<?php echo htmlspecialchars($this->params->get('tag_list_image'), ENT_QUOTES, 'UTF-8'); ?>">
		<?php endif; ?>
		<?php if ($this->params->get('tag_list_description', '') > '') : ?>
			<?php echo JHtml::_('content.prepare', $this->params->get('tag_list_description'), '', 'com_tags.tag'); ?>
		<?php endif; ?>
	<?php endif; ?>
	<?php echo $this->loadTemplate('items'); ?>
</div>
PK
~!]/���views/tag/tmpl/list_items.phpnu&1i�<?php
/**
 * @package     Joomla.Site
 * @subpackage  com_tags
 *
 * @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::_('behavior.core');
JHtml::_('formbehavior.chosen', 'select');

$listOrder = $this->escape($this->state->get('list.ordering'));
$listDirn  = $this->escape($this->state->get('list.direction'));

JFactory::getDocument()->addScriptDeclaration("
		var resetFilter = function() {
		document.getElementById('filter-search').value = '';
	}
");

?>
<form action="<?php echo htmlspecialchars(JUri::getInstance()->toString()); ?>" method="post" name="adminForm" id="adminForm">
	<?php if ($this->params->get('filter_field') || $this->params->get('show_pagination_limit')) : ?>
		<fieldset class="filters btn-toolbar">
			<?php if ($this->params->get('filter_field')) : ?>
				<div class="btn-group">
					<label class="filter-search-lbl element-invisible" for="filter-search">
						<?php echo JText::_('COM_TAGS_TITLE_FILTER_LABEL') . '&#160;'; ?>
					</label>
					<input type="text" name="filter-search" id="filter-search" value="<?php echo $this->escape($this->state->get('list.filter')); ?>" class="inputbox" onchange="document.adminForm.submit();" title="<?php echo JText::_('COM_TAGS_FILTER_SEARCH_DESC'); ?>" placeholder="<?php echo JText::_('COM_TAGS_TITLE_FILTER_LABEL'); ?>" />
					<button type="button" name="filter-search-button" title="<?php echo JText::_('JSEARCH_FILTER_SUBMIT'); ?>" onclick="document.adminForm.submit();" class="btn">
						<span class="icon-search"></span>
					</button>
					<button type="reset" name="filter-clear-button" title="<?php echo JText::_('JSEARCH_FILTER_CLEAR'); ?>" class="btn" onclick="resetFilter(); document.adminForm.submit();">
						<span class="icon-remove"></span>
					</button>
				</div>
			<?php endif; ?>
			<?php if ($this->params->get('show_pagination_limit')) : ?>
				<div class="btn-group pull-right">
					<label for="limit" class="element-invisible">
						<?php echo JText::_('JGLOBAL_DISPLAY_NUM'); ?>
					</label>
					<?php echo $this->pagination->getLimitBox(); ?>
				</div>
			<?php endif; ?>
			<input type="hidden" name="filter_order" value="" />
			<input type="hidden" name="filter_order_Dir" value="" />
			<input type="hidden" name="limitstart" value="" />
			<input type="hidden" name="task" value="" />
			<div class="clearfix"></div>
		</fieldset>
	<?php endif; ?>
	<?php if (empty($this->items)) : ?>
		<p><?php echo JText::_('COM_TAGS_NO_ITEMS'); ?></p>
	<?php else : ?>
		<table class="category table table-striped table-bordered table-hover">
			<?php if ($this->params->get('show_headings')) : ?>
				<thead>
					<tr>
						<th id="categorylist_header_title">
							<?php echo JHtml::_('grid.sort', 'JGLOBAL_TITLE', 'c.core_title', $listDirn, $listOrder); ?>
						</th>
						<?php if ($date = $this->params->get('tag_list_show_date')) : ?>
							<th id="categorylist_header_date">
								<?php if ($date === 'created') : ?>
									<?php echo JHtml::_('grid.sort', 'COM_TAGS_' . $date . '_DATE', 'c.core_created_time', $listDirn, $listOrder); ?>
								<?php elseif ($date === 'modified') : ?>
									<?php echo JHtml::_('grid.sort', 'COM_TAGS_' . $date . '_DATE', 'c.core_modified_time', $listDirn, $listOrder); ?>
								<?php elseif ($date === 'published') : ?>
									<?php echo JHtml::_('grid.sort', 'COM_TAGS_' . $date . '_DATE', 'c.core_publish_up', $listDirn, $listOrder); ?>
								<?php endif; ?>
							</th>
						<?php endif; ?>
					</tr>
				</thead>
			<?php endif; ?>
			<tbody>
				<?php foreach ($this->items as $i => $item) : ?>
					<?php if ($item->core_state == 0) : ?>
						<tr class="system-unpublished cat-list-row<?php echo $i % 2; ?>">
					<?php else : ?>
						<tr class="cat-list-row<?php echo $i % 2; ?>">
					<?php endif; ?>
						<td <?php if ($this->params->get('show_headings')) echo "headers=\"categorylist_header_title\""; ?> class="list-title">
							<a href="<?php echo JRoute::_($item->link); ?>">
								<?php echo $this->escape($item->core_title); ?>
							</a>
							<?php if ($item->core_state == 0) : ?>
								<span class="list-published label label-warning">
									<?php echo JText::_('JUNPUBLISHED'); ?>
								</span>
							<?php endif; ?>
						</td>
						<?php if ($this->params->get('tag_list_show_date')) : ?>
							<td headers="categorylist_header_date" class="list-date small">
								<?php
								echo JHtml::_(
									'date', $item->displayDate,
									$this->escape($this->params->get('date_format', JText::_('DATE_FORMAT_LC3')))
								); ?>
							</td>
						<?php endif; ?>
					</tr>
				<?php endforeach; ?>
			</tbody>
		</table>
		<?php // Add pagination links ?>
		<?php if (($this->params->def('show_pagination', 2) == 1 || ($this->params->get('show_pagination') == 2)) && ($this->pagination->pagesTotal > 1)) : ?>
			<div class="pagination">
				<?php if ($this->params->def('show_pagination_results', 1)) : ?>
					<p class="counter pull-right">
						<?php echo $this->pagination->getPagesCounter(); ?>
					</p>
				<?php endif; ?>
				<?php echo $this->pagination->getPagesLinks(); ?>
			</div>
		<?php endif; ?>
	<?php endif; ?>
</form>
PK
~!]��6�qq views/tag/tmpl/default_items.phpnu&1i�<?php
/**
 * @package     Joomla.Site
 * @subpackage  com_tags
 *
 * @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::_('behavior.core');
JHtml::_('formbehavior.chosen', 'select');

// Get the user object.
$user = JFactory::getUser();

// Check if user is allowed to add/edit based on tags permissions.
// Do we really have to make it so people can see unpublished tags???
$canEdit      = $user->authorise('core.edit', 'com_tags');
$canCreate    = $user->authorise('core.create', 'com_tags');
$canEditState = $user->authorise('core.edit.state', 'com_tags');

JFactory::getDocument()->addScriptDeclaration("
		var resetFilter = function() {
		document.getElementById('filter-search').value = '';
	}
");

?>
<form action="<?php echo htmlspecialchars(JUri::getInstance()->toString()); ?>" method="post" name="adminForm" id="adminForm" class="form-inline">
	<?php if ($this->params->get('show_headings') || $this->params->get('filter_field') || $this->params->get('show_pagination_limit')) : ?>
		<fieldset class="filters btn-toolbar">
			<?php if ($this->params->get('filter_field')) : ?>
				<div class="btn-group">
					<label class="filter-search-lbl element-invisible" for="filter-search">
						<?php echo JText::_('COM_TAGS_TITLE_FILTER_LABEL') . '&#160;'; ?>
					</label>
					<input type="text" name="filter-search" id="filter-search" value="<?php echo $this->escape($this->state->get('list.filter')); ?>" class="inputbox" onchange="document.adminForm.submit();" title="<?php echo JText::_('COM_TAGS_FILTER_SEARCH_DESC'); ?>" placeholder="<?php echo JText::_('COM_TAGS_TITLE_FILTER_LABEL'); ?>" />
					<button type="button" name="filter-search-button" title="<?php echo JText::_('JSEARCH_FILTER_SUBMIT'); ?>" onclick="document.adminForm.submit();" class="btn">
						<span class="icon-search"></span>
					</button>
					<button type="reset" name="filter-clear-button" title="<?php echo JText::_('JSEARCH_FILTER_CLEAR'); ?>" class="btn" onclick="resetFilter(); document.adminForm.submit();">
						<span class="icon-remove"></span>
					</button>
				</div>
			<?php endif; ?>
			<?php if ($this->params->get('show_pagination_limit')) : ?>
				<div class="btn-group pull-right">
					<label for="limit" class="element-invisible">
						<?php echo JText::_('JGLOBAL_DISPLAY_NUM'); ?>
					</label>
					<?php echo $this->pagination->getLimitBox(); ?>
				</div>
			<?php endif; ?>
			<input type="hidden" name="filter_order" value="" />
			<input type="hidden" name="filter_order_Dir" value="" />
			<input type="hidden" name="limitstart" value="" />
			<input type="hidden" name="task" value="" />
			<div class="clearfix"></div>
		</fieldset>
	<?php endif; ?>
	<?php if (empty($this->items)) : ?>
		<p><?php echo JText::_('COM_TAGS_NO_ITEMS'); ?></p>
	<?php else : ?>
		<ul class="category list-striped">
			<?php foreach ($this->items as $i => $item) : ?>
				<?php if ($item->core_state == 0) : ?>
					<li class="system-unpublished cat-list-row<?php echo $i % 2; ?>">
				<?php else : ?>
					<li class="cat-list-row<?php echo $i % 2; ?> clearfix">
				<?php endif; ?>
				<?php if (($item->type_alias === 'com_users.category') || ($item->type_alias === 'com_banners.category')) : ?>
					<h3>
						<?php echo $this->escape($item->core_title); ?>
					</h3>
				<?php else : ?>
					<h3>
						<a href="<?php echo JRoute::_($item->link); ?>">
							<?php echo $this->escape($item->core_title); ?>
						</a>
					</h3>
				<?php endif; ?>
				<?php // Content is generated by content plugin event "onContentAfterTitle" ?>
				<?php echo $item->event->afterDisplayTitle; ?>
				<?php $images = json_decode($item->core_images); ?>
				<?php if ($this->params->get('tag_list_show_item_image', 1) == 1 && !empty($images->image_intro)) : ?>
					<a href="<?php echo JRoute::_($item->link); ?>">
						<img src="<?php echo htmlspecialchars($images->image_intro); ?>" alt="<?php echo htmlspecialchars($images->image_intro_alt); ?>">
					</a>
				<?php endif; ?>
				<?php if ($this->params->get('tag_list_show_item_description', 1)) : ?>
					<?php // Content is generated by content plugin event "onContentBeforeDisplay" ?>
					<?php echo $item->event->beforeDisplayContent; ?>
					<span class="tag-body">
						<?php echo JHtml::_('string.truncate', $item->core_body, $this->params->get('tag_list_item_maximum_characters')); ?>
					</span>
					<?php // Content is generated by content plugin event "onContentAfterDisplay" ?>
					<?php echo $item->event->afterDisplayContent; ?>
				<?php endif; ?>
				</li>
			<?php endforeach; ?>
		</ul>
	<?php endif; ?>
</form>
PK
~!]��=���views/tags/view.feed.phpnu&1i�<?php
/**
 * @package     Joomla.Site
 * @subpackage  com_tags
 *
 * @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;

/**
 * HTML View class for the Tags component all tags view
 *
 * @since  3.1
 */
class TagsViewTags extends JViewLegacy
{
	/**
	 * 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();
		$document       = JFactory::getDocument();
		$document->link = JRoute::_('index.php?option=com_tags&view=tags');

		$app->input->set('limit', $app->get('feed_limit'));
		$siteEmail        = $app->get('mailfrom');
		$fromName         = $app->get('fromname');
		$feedEmail        = $app->get('feed_email', 'none');
		$document->editor = $fromName;

		if ($feedEmail !== 'none')
		{
			$document->editorEmail = $siteEmail;
		}

		// Get some data from the model
		$items = $this->get('Items');

		foreach ($items as $item)
		{
			// Strip HTML from feed item title
			$title = $this->escape($item->title);
			$title = html_entity_decode($title, ENT_COMPAT, 'UTF-8');

			// Strip HTML from feed item description text
			$description = $item->description;
			$author      = $item->created_by_alias ?: $item->created_by_user_name;
			$date        = $item->created_time ? date('r', strtotime($item->created_time)) : '';

			// Load individual item creator class
			$feeditem = new JFeedItem;
			$feeditem->title       = $title;
			$feeditem->link        = '/index.php?option=com_tags&view=tag&id=' . (int) $item->id;
			$feeditem->description = $description;
			$feeditem->date        = $date;
			$feeditem->category    = 'All Tags';
			$feeditem->author      = $author;

			if ($feedEmail === 'site')
			{
				$feeditem->authorEmail = $siteEmail;
			}

			if ($feedEmail === 'author')
			{
				$feeditem->authorEmail = $item->email;
			}

			// Loads item info into RSS array
			$document->addItem($feeditem);
		}
	}
}
PK
~!]�J?��!views/tags/tmpl/default_items.phpnu&1i�<?php
/**
 * @package     Joomla.Site
 * @subpackage  com_tags
 *
 * @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::addIncludePath(JPATH_COMPONENT . '/helpers');

JHtml::_('behavior.caption');
JHtml::_('behavior.core');

// Get the user object.
$user = JFactory::getUser();

// Check if user is allowed to add/edit based on tags permissions.
$canEdit      = $user->authorise('core.edit', 'com_tags');
$canCreate    = $user->authorise('core.create', 'com_tags');
$canEditState = $user->authorise('core.edit.state', 'com_tags');

$columns = $this->params->get('tag_columns', 1);

// Avoid division by 0 and negative columns.
if ($columns < 1)
{
	$columns = 1;
}

$bsspans = floor(12 / $columns);

if ($bsspans < 1)
{
	$bsspans = 1;
}

$bscolumns = min($columns, floor(12 / $bsspans));
$n         = count($this->items);

JFactory::getDocument()->addScriptDeclaration("
		var resetFilter = function() {
		document.getElementById('filter-search').value = '';
	}
");

?>
<form action="<?php echo htmlspecialchars(JUri::getInstance()->toString()); ?>" method="post" name="adminForm" id="adminForm">
	<?php if ($this->params->get('filter_field') || $this->params->get('show_pagination_limit')) : ?>
		<fieldset class="filters btn-toolbar">
			<?php if ($this->params->get('filter_field')) : ?>
				<div class="btn-group">
					<label class="filter-search-lbl element-invisible" for="filter-search">
						<?php echo JText::_('COM_TAGS_TITLE_FILTER_LABEL') . '&#160;'; ?>
					</label>
					<input type="text" name="filter-search" id="filter-search" value="<?php echo $this->escape($this->state->get('list.filter')); ?>" class="inputbox" onchange="document.adminForm.submit();" title="<?php echo JText::_('COM_TAGS_FILTER_SEARCH_DESC'); ?>" placeholder="<?php echo JText::_('COM_TAGS_TITLE_FILTER_LABEL'); ?>" />
					<button type="button" name="filter-search-button" title="<?php echo JText::_('JSEARCH_FILTER_SUBMIT'); ?>" onclick="document.adminForm.submit();" class="btn">
						<span class="icon-search"></span>
					</button>
					<button type="reset" name="filter-clear-button" title="<?php echo JText::_('JSEARCH_FILTER_CLEAR'); ?>" class="btn" onclick="resetFilter(); document.adminForm.submit();">
						<span class="icon-remove"></span>
					</button>
				</div>
			<?php endif; ?>
			<?php if ($this->params->get('show_pagination_limit')) : ?>
				<div class="btn-group pull-right">
					<label for="limit" class="element-invisible">
						<?php echo JText::_('JGLOBAL_DISPLAY_NUM'); ?>
					</label>
					<?php echo $this->pagination->getLimitBox(); ?>
				</div>
			<?php endif; ?>
			<input type="hidden" name="filter_order" value="" />
			<input type="hidden" name="filter_order_Dir" value="" />
			<input type="hidden" name="limitstart" value="" />
			<input type="hidden" name="task" value="" />
			<div class="clearfix"></div>
		</fieldset>
	<?php endif; ?>
	<?php if ($this->items == false || $n === 0) : ?>
		<p><?php echo JText::_('COM_TAGS_NO_TAGS'); ?></p>
	<?php else : ?>
		<?php foreach ($this->items as $i => $item) : ?>
			<?php if ($n === 1 || $i === 0 || $bscolumns === 1 || $i % $bscolumns === 0) : ?>
				<ul class="thumbnails">
			<?php endif; ?>
			<?php if ((!empty($item->access)) && in_array($item->access, $this->user->getAuthorisedViewLevels())) : ?>
				<li class="cat-list-row<?php echo $i % 2; ?>">
					<h3>
						<a href="<?php echo JRoute::_(TagsHelperRoute::getTagRoute($item->id . ':' . $item->alias)); ?>">
							<?php echo $this->escape($item->title); ?>
						</a>
					</h3>
			<?php endif; ?>
			<?php if ($this->params->get('all_tags_show_tag_image') && !empty($item->images)) : ?>
				<?php $images  = json_decode($item->images); ?>
				<span class="tag-body">
					<?php if (!empty($images->image_intro)) : ?>
						<?php $imgfloat = empty($images->float_intro) ? $this->params->get('float_intro') : $images->float_intro; ?>
						<div class="pull-<?php echo htmlspecialchars($imgfloat, ENT_QUOTES, 'UTF-8'); ?> item-image">
							<img
								<?php if ($images->image_intro_caption) : ?>
									<?php echo 'class="caption"' . ' title="' . htmlspecialchars($images->image_intro_caption, ENT_QUOTES, 'UTF-8') . '"'; ?>
								<?php endif; ?>
								src="<?php echo htmlspecialchars($images->image_intro, ENT_QUOTES, 'UTF-8'); ?>"
								alt="<?php echo htmlspecialchars($images->image_intro_alt, ENT_QUOTES, 'UTF-8'); ?>" />
						</div>
					<?php endif; ?>
				</span>
			<?php endif; ?>
			<?php if (($this->params->get('all_tags_show_tag_description', 1) && !empty($item->description)) || $this->params->get('all_tags_show_tag_hits')) : ?>
				<div class="caption">
					<?php if ($this->params->get('all_tags_show_tag_description', 1) && !empty($item->description)) : ?>
						<span class="tag-body">
							<?php echo JHtml::_('string.truncate', $item->description, $this->params->get('all_tags_tag_maximum_characters')); ?>
						</span>
					<?php endif; ?>
					<?php if ($this->params->get('all_tags_show_tag_hits')) : ?>
						<span class="list-hits badge badge-info">
							<?php echo JText::sprintf('JGLOBAL_HITS_COUNT', $item->hits); ?>
						</span>
					<?php endif; ?>
				</div>
			<?php endif; ?>
			</li>
			<?php if (($i === 0 && $n === 1) || $i === $n - 1 || $bscolumns === 1 || (($i + 1) % $bscolumns === 0)) : ?>
				</ul>
			<?php endif; ?>
		<?php endforeach; ?>
	<?php endif; ?>
	<?php // Add pagination links ?>
	<?php if (!empty($this->items)) : ?>
		<?php if (($this->params->def('show_pagination', 2) == 1 || ($this->params->get('show_pagination') == 2)) && ($this->pagination->pagesTotal > 1)) : ?>
			<div class="pagination">
				<?php if ($this->params->def('show_pagination_results', 1)) : ?>
					<p class="counter pull-right">
						<?php echo $this->pagination->getPagesCounter(); ?>
					</p>
				<?php endif; ?>
				<?php echo $this->pagination->getPagesLinks(); ?>
			</div>
		<?php endif; ?>
	<?php endif; ?>
</form>
PK
~!]T<���
router.phpnu&1i�<?php
/**
 * @package     Joomla.Site
 * @subpackage  com_tags
 *
 * @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;

use Joomla\Utilities\ArrayHelper;

/**
 * Routing class from com_tags
 *
 * @since  3.3
 */
class TagsRouter extends JComponentRouterBase
{
	/**
	 * Build the route for the com_tags component
	 *
	 * @param   array  &$query  An array of URL arguments
	 *
	 * @return  array  The URL arguments to use to assemble the subsequent URL.
	 *
	 * @since   3.3
	 */
	public function build(&$query)
	{
		$segments = array();

		// Get a menu item based on Itemid or currently active
		$params = JComponentHelper::getParams('com_tags');

		// We need a menu item.  Either the one specified in the query, or the current active one if none specified
		if (empty($query['Itemid']))
		{
			$menuItem = $this->menu->getActive();
		}
		else
		{
			$menuItem = $this->menu->getItem($query['Itemid']);
		}

		$mView = empty($menuItem->query['view']) ? null : $menuItem->query['view'];
		$mId   = empty($menuItem->query['id']) ? null : $menuItem->query['id'];

		if (is_array($mId))
		{
			$mId = ArrayHelper::toInteger($mId);
		}

		$view = '';

		if (isset($query['view']))
		{
			$view = $query['view'];

			if (empty($query['Itemid']))
			{
				$segments[] = $view;
			}

			unset($query['view']);
		}

		// Are we dealing with a tag that is attached to a menu item?
		if ($mView == $view && isset($query['id']) && $mId == $query['id'])
		{
			unset($query['id']);

			return $segments;
		}

		if ($view === 'tag')
		{
			$notActiveTag = is_array($mId) ? (count($mId) > 1 || $mId[0] != (int) $query['id']) : ($mId != (int) $query['id']);

			if ($notActiveTag || $mView != $view)
			{
				// ID in com_tags can be either an integer, a string or an array of IDs
				$id = is_array($query['id']) ? implode(',', $query['id']) : $query['id'];
				$segments[] = $id;
			}

			unset($query['id']);
		}

		if (isset($query['layout']))
		{
			if ((!empty($query['Itemid']) && isset($menuItem->query['layout'])
				&& $query['layout'] == $menuItem->query['layout'])
				|| $query['layout'] === 'default')
			{
				unset($query['layout']);
			}
		}

		$total = count($segments);

		for ($i = 0; $i < $total; $i++)
		{
			$segments[$i] = str_replace(':', '-', $segments[$i]);
			$position     = strpos($segments[$i], '-');

			if ($position)
			{
				// Remove id from segment
				$segments[$i] = substr($segments[$i], $position + 1);
			}
		}

		return $segments;
	}

	/**
	 * Parse the segments of a URL.
	 *
	 * @param   array  &$segments  The segments of the URL to parse.
	 *
	 * @return  array  The URL attributes to be used by the application.
	 *
	 * @since   3.3
	 */
	public function parse(&$segments)
	{
		$total = count($segments);
		$vars = array();

		for ($i = 0; $i < $total; $i++)
		{
			$segments[$i] = preg_replace('/-/', ':', $segments[$i], 1);
		}

		// Get the active menu item.
		$item = $this->menu->getActive();

		// Count route segments
		$count = count($segments);

		// Standard routing for tags.
		if (!isset($item))
		{
			$vars['view'] = $segments[0];
			$vars['id']   = $this->fixSegment($segments[$count - 1]);

			return $vars;
		}

		$vars['id'] = $this->fixSegment($segments[0]);
		$vars['view'] = 'tag';

		return $vars;
	}

	/**
	 * Try to add missing id to segment
	 *
	 * @param   string  $segment  One piece of segment of the URL to parse
	 *
	 * @return  string  The segment with founded id
	 *
	 * @since   3.7
	 */
	protected function fixSegment($segment)
	{
		$db = JFactory::getDbo();

		// Try to find tag id
		$alias = str_replace(':', '-', $segment);

		$query = $db->getQuery(true)
			->select('id')
			->from($db->quoteName('#__tags'))
			->where($db->quoteName('alias') . " = " . $db->quote($alias));

		$id = $db->setQuery($query)->loadResult();

		if ($id)
		{
			$segment = "$id:$alias";
		}

		return $segment;
	}
}

/**
 * Tags router functions. These functions are proxys for the new router interface or old SEF extensions.
 *
 * @param   array  &$query  An array of URL arguments.
 *
 * @return array
 *
 * @deprecated  4.0  Use Class based routers instead
 */
function tagsBuildRoute(&$query)
{
	$router = new TagsRouter;

	return $router->build($query);
}

/**
 * Parse the segments of a URL. These functions are proxys for the new router interface or old SEF extensions.
 *
 * @param   array  $segments  The segments of the URL to parse.
 *
 * @return  array  The URL attributes to be used by the application.
 *
 * @deprecated  4.0  Use Class based routers instead
 */
function tagsParseRoute($segments)
{
	$router = new TagsRouter;

	return $router->parse($segments);
}
PK3�!]
{��tags/default.phpnu&1i�<?php
/**
 * @package     Joomla.Administrator
 * @subpackage  Template.hathor
 *
 * @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::addIncludePath(JPATH_COMPONENT.'/helpers/html');

JHtml::_('behavior.multiselect');

$app       = JFactory::getApplication();
$user      = JFactory::getUser();
$userId    = $user->get('id');
$listOrder = $this->escape($this->state->get('list.ordering'));
$listDirn  = $this->escape($this->state->get('list.direction'));
$saveOrder = $listOrder == 'a.ordering';
$n         = count($this->items);
?>

<form action="<?php echo JRoute::_('index.php?option=com_tags&view=tags');?>" method="post" name="adminForm" id="adminForm">
<?php if (!empty( $this->sidebar)) : ?>
	<div id="j-sidebar-container" class="span2">
		<?php echo $this->sidebar; ?>
	</div>
	<div id="j-main-container" class="span10">
<?php else : ?>
	<div id="j-main-container">
<?php endif;?>
	<fieldset id="filter-bar">
	<legend class="element-invisible"><?php echo JText::_('JSEARCH_FILTER_LABEL'); ?></legend>
		<div class="filter-search">
			<label class="filter-search-lbl" for="filter_search"><?php echo JText::_('JSEARCH_FILTER_LABEL'); ?></label>
			<input type="text" name="filter_search" id="filter_search" value="<?php echo $this->escape($this->state->get('filter.search')); ?>" title="<?php echo JText::_('COM_TAGS_FILTER_SEARCH_DESC'); ?>" />
			<button type="submit" class="btn"><?php echo JText::_('JSEARCH_FILTER_SUBMIT'); ?></button>
			<button type="button" onclick="document.getElementById('filter_search').value='';this.form.submit();"><?php echo JText::_('JSEARCH_FILTER_CLEAR'); ?></button>
		</div>

		<div class="filter-select">
			<label class="selectlabel" for="filter_published"><?php echo JText::_('JOPTION_SELECT_PUBLISHED'); ?></label>
			<select name="filter_published" id="filter_published">
				<option value=""><?php echo JText::_('JOPTION_SELECT_PUBLISHED'); ?></option>
				<?php echo JHtml::_('select.options', JHtml::_('jgrid.publishedOptions'), 'value', 'text', $this->state->get('filter.published'), true); ?>
			</select>

			<label class="selectlabel" for="filter_access"><?php echo JText::_('JOPTION_SELECT_ACCESS'); ?></label>
			<select name="filter_access" id="filter_access">
				<option value=""><?php echo JText::_('JOPTION_SELECT_ACCESS'); ?></option>
				<?php echo JHtml::_('select.options', JHtml::_('access.assetgroups'), 'value', 'text', $this->state->get('filter.access')); ?>
			</select>

			<label class="selectlabel" for="filter_author_id"><?php echo JText::_('JOPTION_SELECT_AUTHOR'); ?></label>
			<select name="filter_author_id" id="filter_author_id">
				<option value=""><?php echo JText::_('JOPTION_SELECT_AUTHOR'); ?></option>
				<?php echo JHtml::_('select.options', $this->authors, 'value', 'text', $this->state->get('filter.author_id')); ?>
			</select>

			<label class="selectlabel" for="filter_language"><?php echo JText::_('JOPTION_SELECT_LANGUAGE'); ?></label>
			<select name="filter_language" id="filter_language">
				<option value=""><?php echo JText::_('JOPTION_SELECT_LANGUAGE'); ?></option>
				<?php echo JHtml::_('select.options', JHtml::_('contentlanguage.existing', true, true), 'value', 'text', $this->state->get('filter.language')); ?>
			</select>

			<button type="submit" id="filter-go">
				<?php echo JText::_('JSUBMIT'); ?></button>
		</div>
	</fieldset>
	<div class="clr"> </div>
	<table class="adminlist">
		<thead>
			<tr>
				<th class="checkmark-col">
					<input type="checkbox" name="checkall-toggle" value="" title="<?php echo JText::_('JGLOBAL_CHECK_ALL'); ?>" onclick="Joomla.checkAll(this)" />
				</th>
				<th class="title">
					<?php echo JHtml::_('grid.sort', 'JGLOBAL_TITLE', 'a.title', $listDirn, $listOrder); ?>
				</th>
				<th class="nowrap state-col">
					<?php echo JHtml::_('grid.sort', 'JSTATUS', 'a.published', $listDirn, $listOrder); ?>
				</th>
				<th class="title access-col">
					<?php echo JHtml::_('grid.sort', 'JGRID_HEADING_ACCESS', 'access', $listDirn, $listOrder); ?>
				<th class="language-col">
					<?php echo JHtml::_('grid.sort', 'JGRID_HEADING_LANGUAGE', 'language', $listDirn, $listOrder); ?>
				</th>
				<th class="nowrap id-col">
					<?php echo JHtml::_('grid.sort', 'JGRID_HEADING_ID', 'a.id', $listDirn, $listOrder); ?>
				</th>
			</tr>
		</thead>

		<tbody>
		<?php foreach ($this->items as $i => $item) :
			$item->max_ordering = 0; //??
			$canCreate  = $user->authorise('core.create',     'com_tags');
			$canEdit    = $user->authorise('core.edit',       'com_tags.tag.' . $item->id);
			$canCheckin = $user->authorise('core.manage',     'com_checkin') || $item->checked_out_user_id == $userId || $item->checked_out_user_id == 0;
			$canChange  = $user->authorise('core.edit.state', 'com_tags.tag.' . $item->id) && $canCheckin;
			?>
			<tr class="row<?php echo $i % 2; ?>">
				<th class="center">
					<?php echo JHtml::_('grid.id', $i, $item->id); ?>
				</th>
				<td>
					<?php if ($item->level > 0): ?>
					<?php echo str_repeat('<span class="gi">&mdash;</span>', $item->level - 1) ?>
					<?php endif; ?>

					<?php if ($item->checked_out) : ?>
						<?php echo JHtml::_('jgrid.checkedout', $i, $item->editor, $item->checked_out_time, 'tags.', $canCheckin); ?>
					<?php endif; ?>
					<?php if ($canEdit || $canEditOwn) : ?>
						<a href="<?php echo JRoute::_('index.php?option=com_tags&task=tag.edit&id='.$item->id); ?>">
							<?php echo $this->escape($item->title); ?></a>
					<?php else : ?>
						<?php echo $this->escape($item->title); ?>
					<?php endif; ?>
					<p class="smallsub">
						<?php echo JText::sprintf('JGLOBAL_LIST_ALIAS', $this->escape($item->alias)); ?></p>
				</td>
				<td class="center">
					<?php echo JHtml::_('jgrid.published', $item->published, $i, 'tags.', $canChange, 'cb'); ?>
				</td>
				<td class="center">
					<?php echo $this->escape($item->access_title); ?>
				</td>
				<td class="center">
					<?php echo JLayoutHelper::render('joomla.content.language', $item); ?>
				</td>
				<td class="center">
					<?php echo (int) $item->id; ?>
				</td>
			</tr>
			<?php endforeach; ?>
		</tbody>
	</table>

	<?php //Load the batch processing form if user is allowed ?>
	<?php if ($user->authorise('core.create', 'com_tags')
		&& $user->authorise('core.edit', 'com_tags')
		&& $user->authorise('core.edit.state', 'com_tags')) : ?>
		<?php echo JHtml::_(
			'bootstrap.renderModal',
			'collapseModal',
			array(
				'title'  => JText::_('COM_TAGS_BATCH_OPTIONS'),
				'footer' => $this->loadTemplate('batch_footer'),
			),
			$this->loadTemplate('batch_body')
		); ?>
	<?php endif;?>

	<?php echo $this->pagination->getListFooter(); ?>

	<input type="hidden" name="task" value="" />
	<input type="hidden" name="boxchecked" value="0" />
	<input type="hidden" name="filter_order" value="<?php echo $listOrder; ?>" />
	<input type="hidden" name="filter_order_Dir" value="<?php echo $listDirn; ?>" />
	<?php echo JHtml::_('form.token'); ?>
	</div>
</form>
PK3�!]˳�AAtag/edit.phpnu&1i�<?php
/**
 * @package     Joomla.Administrator
 * @subpackage  Template.hathor
 *
 * @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::addIncludePath(JPATH_COMPONENT.'/helpers/html');

$saveHistory = $this->state->get('params')->get('save_history', 0);

JHtml::_('behavior.formvalidator');

JFactory::getDocument()->addScriptDeclaration("
	Joomla.submitbutton = function(task)
	{
		if (task == 'tag.cancel' || document.formvalidator.isValid(document.getElementById('tag-form')))
		{
			" . $this->form->getField('description')->save() . "
			Joomla.submitform(task, document.getElementById('tag-form'));
		}
	}
");
?>

<div class="weblink-edit">

<form action="<?php echo JRoute::_('index.php?option=com_tags&layout=edit&id='.(int) $this->item->id); ?>" method="post" name="adminForm" id="tag-form" class="form-validate">
	<div class="col main-section">
		<fieldset class="adminform">
			<legend><?php echo empty($this->item->id) ? JText::_('JTOOLBAR_NEW') : JText::sprintf('JTOOLBAR_EDIT', $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('parent_id'); ?>
				<?php echo $this->form->getInput('parent_id'); ?></li>

				<li><?php echo $this->form->getLabel('published'); ?>
				<?php echo $this->form->getInput('published'); ?></li>

				<li><?php echo $this->form->getLabel('access'); ?>
				<?php echo $this->form->getInput('access'); ?></li>

				<li><?php echo $this->form->getLabel('language'); ?>
				<?php echo $this->form->getInput('language'); ?></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>
				<?php echo $this->form->getLabel('description'); ?>
				<div class="clr"></div>
				<?php echo $this->form->getInput('description'); ?>
			</div>
		</fieldset>
	</div>

	<div class="col options-section">
		<?php echo JHtml::_('sliders.start', 'weblink-sliders-'.$this->item->id, array('useCookie' => 1)); ?>

		<?php echo JHtml::_('sliders.panel', JText::_('JGLOBAL_FIELDSET_PUBLISHING'), 'publishing-details'); ?>

		<fieldset class="panelform">
			<legend class="element-invisible"><?php echo JText::_('JGLOBAL_FIELDSET_PUBLISHING'); ?></legend>
			<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_user_id) : ?>
					<li><?php echo $this->form->getLabel('modified_user_id'); ?>
					<?php echo $this->form->getInput('modified_user_id'); ?></li>

					<li><?php echo $this->form->getLabel('modified'); ?>
					<?php echo $this->form->getInput('modified'); ?></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 echo $this->loadTemplate('options'); ?>

		<?php echo $this->loadTemplate('metadata'); ?>

		<?php echo JHtml::_('sliders.end'); ?>

		<input type="hidden" name="task" value="" />
		<?php echo JHtml::_('form.token'); ?>
	</div>
	<div class="clr"></div>
</form>
</div>

PK3�!];�����tag/edit_options.phpnu&1i�<?php
/**
 * @package     Joomla.Administrator
 * @subpackage  Template.hathor
 *
 * @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;

if (isset($fieldSet->description) && trim($fieldSet->description)) :
	echo '<p class="tip">'.$this->escape(JText::_($fieldSet->description)).'</p>';
endif;
?>
<fieldset class="panelform">
	<legend class="element-invisible"><?php echo JText::_($fieldSet->label); ?></legend>
	<ul class="adminformlist">
			<li><?php echo $this->form->getLabel('created_user_id'); ?>
			<?php echo $this->form->getInput('created_user_id'); ?></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_time'); ?>
			<?php echo $this->form->getInput('created_time'); ?></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>

			<li><?php echo $this->form->getLabel('modified_user_id'); ?>
			<?php echo $this->form->getInput('modified_user_id'); ?></li>

			<li><?php echo $this->form->getLabel('modified_time'); ?>
			<?php echo $this->form->getInput('modified_time'); ?></li>
			<li><?php echo $this->form->getLabel('version'); ?>
			<?php echo $this->form->getInput('version'); ?></li>


			</ul>
</fieldset>

<?php $fieldSets = $this->form->getFieldsets('params');
	foreach ($fieldSets as $name => $fieldSet) :
	echo JHtml::_('sliders.panel', JText::_($fieldSet->label), $name.'-params');
	if (isset($fieldSet->description) && trim($fieldSet->description)) :
		echo '<p class="tip">'.$this->escape(JText::_($fieldSet->description)).'</p>';
	endif;
	?>
	<fieldset class="panelform">
		<legend class="element-invisible"><?php echo JText::_($fieldSet->label); ?></legend>
		<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 endforeach; ?>
PK3�!]vW:���tag/edit_metadata.phpnu&1i�<?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;

$fieldSets = $this->form->getFieldsets('metadata');
foreach ($fieldSets as $name => $fieldSet) :
	echo JHtml::_('sliders.panel', JText::_($fieldSet->label), $name.'-options');
	if (isset($fieldSet->description) && trim($fieldSet->description)) :
		echo '<p class="tip">'.$this->escape(JText::_($fieldSet->description)).'</p>';
	endif;
	?>
	<fieldset class="panelform">
	<legend class="element-invisible"><?php echo JText::_($fieldSet->label); ?></legend>
		<ul class="adminformlist">
			<?php if ($name == 'jmetadata') : // Include the real fields in this panel. ?>
				<li><?php echo $this->form->getLabel('metadesc'); ?>
				<?php echo $this->form->getInput('metadesc'); ?></li>

				<li><?php echo $this->form->getLabel('metakey'); ?>
				<?php echo $this->form->getInput('metakey'); ?></li>

				<li><?php echo $this->form->getLabel('xreference'); ?>
				<?php echo $this->form->getInput('xreference'); ?></li>
			<?php endif; ?>
			<?php foreach ($this->form->getFieldset($name) as $field) : ?>
				<li><?php echo $field->label; ?>
				<?php echo $field->input; ?></li>
			<?php endforeach; ?>
		</ul>
	</fieldset>
<?php endforeach; ?>
PK�|!]�‚-vvhelpers/tags.phpnu&1i�PK�|!]�tx�DD�controllers/tags.phpnu&1i�PK�|!]��'��>controllers/tag.phpnu&1i�PK�|!](��11
}access.xmlnu&1i�PK�|!]�x����tags.xmlnu&1i�PK�|!]��/�)�)
�config.xmlnu&1i�PK�|!]=�ӻ���Dtags.phpnu&1i�PK�|!]�C%�Ftables/tag.phpnu&1i�PK�|!]��1�yy�^controller.phpnu&1i�PK�|!]�L��
�
�dmodels/forms/filter_tags.xmlnu&1i�PK�|!]��.���omodels/forms/tag.xmlnu&1i�PK�|!]�Ϙ##��models/tag.phpnu&1i�PK�|!]A�p�����models/tags.phpnu&1i�PK�|!]gg�&}}&��views/tags/tmpl/default_batch_body.phpnu&1i�PK�|!]�oo��views/tags/tmpl/default.phpnu&1i�PK�|!]�䁴�(��views/tags/tmpl/default_batch_footer.phpnu&1i�PK�|!]�΄aa��views/tags/tmpl/default.xmlnu&1i�PK�|!]���}��;�views/tags/view.html.phpnu&1i�PK�|!]	Rn��F�views/tag/tmpl/edit.phpnu&1i�PK�|!]��`B__ rviews/tag/tmpl/edit_metadata.phpnu&1i�PK�|!]t�U��!	views/tag/tmpl/edit_options.phpnu&1i�PK�|!]W-}�+&+&bviews/tag/view.html.phpnu&1i�PK
~!]҆b(���7helpers/route.phpnu&1i�PK
~!]�b�%

�Kviews/tag/view.feed.phpnu&1i�PK
~!]I��s		'Vviews/tag/tmpl/default.xmlnu&1i�PK
~!]�?�__zpviews/tag/tmpl/default.phpnu&1i�PK
~!]�&&#|views/tag/tmpl/list.xmlnu&1i�PK
~!]\�5�/	/	��views/tag/tmpl/list.phpnu&1i�PK
~!]/����views/tag/tmpl/list_items.phpnu&1i�PK
~!]��6�qq ��views/tag/tmpl/default_items.phpnu&1i�PK
~!]��=�����views/tags/view.feed.phpnu&1i�PK
~!]�J?��!��views/tags/tmpl/default_items.phpnu&1i�PK
~!]T<���
��router.phpnu&1i�PK3�!]
{����tags/default.phpnu&1i�PK3�!]˳�AA�tag/edit.phpnu&1i�PK3�!];�����,tag/edit_options.phpnu&1i�PK3�!]vW:���)5tag/edit_metadata.phpnu&1i�PK%%\�: