Your IP : 216.73.217.167


Current Path : /proc/thread-self/root/proc/thread-self/root/proc/1908984/root/proc/2411249/cwd/
Upload File :
Current File : //proc/thread-self/root/proc/thread-self/root/proc/1908984/root/proc/2411249/cwd/installed.php.tar

home/digilove/public_html/plugins/system/advancedmodules/vendor/composer/installed.php000064400000001334152351605710025565 0ustar00<?php return array(
    'root' => array(
        'pretty_version' => 'dev-main',
        'version' => 'dev-main',
        'type' => 'library',
        'install_path' => __DIR__ . '/../../',
        'aliases' => array(),
        'reference' => '1005f7331037063170ca4f1a6861984f9b932586',
        'name' => '__root__',
        'dev' => true,
    ),
    'versions' => array(
        '__root__' => array(
            'pretty_version' => 'dev-main',
            'version' => 'dev-main',
            'type' => 'library',
            'install_path' => __DIR__ . '/../../',
            'aliases' => array(),
            'reference' => '1005f7331037063170ca4f1a6861984f9b932586',
            'dev_requirement' => false,
        ),
    ),
);
home/digilove/public_html/administrator/components/com_languages/controllers/installed.php000064400000005045152415135470026522 0ustar00<?php
/**
 * @package     Joomla.Administrator
 * @subpackage  com_languages
 *
 * @copyright   (C) 2009 Open Source Matters, Inc. <https://www.joomla.org>
 * @license     GNU General Public License version 2 or later; see LICENSE.txt
 */

defined('_JEXEC') or die;

/**
 * Languages Controller.
 *
 * @since  1.5
 */
class LanguagesControllerInstalled extends JControllerLegacy
{
	/**
	 * Task to set the default language.
	 *
	 * @return  void
	 */
	public function setDefault()
	{
		// Check for request forgeries.
		$this->checkToken();

		$cid = (string) $this->input->get('cid', '', 'string');
		$model = $this->getModel('installed');

		if ($model->publish($cid))
		{
			// Switching to the new administrator language for the message
			if ($model->getState('client_id') == 1)
			{
				$language = JFactory::getLanguage();
				$newLang = JLanguage::getInstance($cid);
				JFactory::$language = $newLang;
				JFactory::getApplication()->loadLanguage($language = $newLang);
				$newLang->load('com_languages', JPATH_ADMINISTRATOR);
			}

			$msg = JText::_('COM_LANGUAGES_MSG_DEFAULT_LANGUAGE_SAVED');
			$type = 'message';
		}
		else
		{
			$msg = $this->getError();
			$type = 'error';
		}

		$clientId = $model->getState('client_id');
		$this->setredirect('index.php?option=com_languages&view=installed&client=' . $clientId, $msg, $type);
	}

	/**
	 * Task to switch the administrator language.
	 *
	 * @return  void
	 */
	public function switchAdminLanguage()
	{
		// Check for request forgeries.
		$this->checkToken();

		$cid = (string) $this->input->get('cid', '', 'string');
		$model = $this->getModel('installed');

		// Fetching the language name from the xx-XX.xml or langmetadata.xml respectively.
		$file = JPATH_ADMINISTRATOR . '/language/' . $cid . '/' . $cid . '.xml';

		if (!is_file($file))
		{
			$file = JPATH_ADMINISTRATOR . '/language/' . $cid . '/langmetadata.xml';
		}

		$info = JInstaller::parseXMLInstallFile($file);

		if ($model->switchAdminLanguage($cid))
		{
			// Switching to the new language for the message
			$languageName = $info['name'];
			$language = JFactory::getLanguage();
			$newLang = JLanguage::getInstance($cid);
			JFactory::$language = $newLang;
			JFactory::getApplication()->loadLanguage($language = $newLang);
			$newLang->load('com_languages', JPATH_ADMINISTRATOR);

			$msg = JText::sprintf('COM_LANGUAGES_MSG_SWITCH_ADMIN_LANGUAGE_SUCCESS', $languageName);
			$type = 'message';
		}
		else
		{
			$msg = $this->getError();
			$type = 'error';
		}

		$this->setredirect('index.php?option=com_languages&view=installed', $msg, $type);
	}
}
home/digilove/public_html/110/libraries/vendor/composer/installed.php000064400000032713152423413070021700 0ustar00<?php return array(
    'root' => array(
        'pretty_version' => 'dev-3.10-dev',
        'version' => 'dev-3.10-dev',
        'type' => 'project',
        'install_path' => __DIR__ . '/../../../',
        'aliases' => array(),
        'reference' => 'f4a39fcfe82e68162a5b12f3537f8d2c673c93f7',
        'name' => 'joomla/joomla-cms',
        'dev' => false,
    ),
    'versions' => array(
        'brumann/polyfill-unserialize' => array(
            'pretty_version' => 'v2.0.0',
            'version' => '2.0.0.0',
            'type' => 'library',
            'install_path' => __DIR__ . '/../brumann/polyfill-unserialize',
            'aliases' => array(),
            'reference' => '46e5c18ee87d8a9b5765ef95468c1ac27bd107bf',
            'dev_requirement' => false,
        ),
        'google/recaptcha' => array(
            'pretty_version' => '1.1.2',
            'version' => '1.1.2.0',
            'type' => 'library',
            'install_path' => __DIR__ . '/../google/recaptcha',
            'aliases' => array(),
            'reference' => '2b7e00566afca82a38a1d3adb8e42c118006296e',
            'dev_requirement' => false,
        ),
        'ircmaxell/password-compat' => array(
            'pretty_version' => 'v1.0.4',
            'version' => '1.0.4.0',
            'type' => 'library',
            'install_path' => __DIR__ . '/../ircmaxell/password-compat',
            'aliases' => array(),
            'reference' => '5c5cde8822a69545767f7c7f3058cb15ff84614c',
            'dev_requirement' => false,
        ),
        'joomla/application' => array(
            'pretty_version' => '1.9.3',
            'version' => '1.9.3.0',
            'type' => 'joomla-package',
            'install_path' => __DIR__ . '/../joomla/application',
            'aliases' => array(),
            'reference' => '2a2fee9fa2ebb07c0d28da07f6e4ea3c56b77d16',
            'dev_requirement' => false,
        ),
        'joomla/archive' => array(
            'pretty_version' => '1.1.12',
            'version' => '1.1.12.0',
            'type' => 'joomla-package',
            'install_path' => __DIR__ . '/../joomla/archive',
            'aliases' => array(),
            'reference' => 'b1c1e6c3aecc0486453cadbb92bc529cfa89a89f',
            'dev_requirement' => false,
        ),
        'joomla/compat' => array(
            'pretty_version' => '1.2.0',
            'version' => '1.2.0.0',
            'type' => 'joomla-package',
            'install_path' => __DIR__ . '/../joomla/compat',
            'aliases' => array(),
            'reference' => 'f23565fe0184517778996226eb4b2333deb369c4',
            'dev_requirement' => false,
        ),
        'joomla/data' => array(
            'pretty_version' => '1.2.0',
            'version' => '1.2.0.0',
            'type' => 'joomla-package',
            'install_path' => __DIR__ . '/../joomla/data',
            'aliases' => array(),
            'reference' => '57ee292ba23307a6a6059e69b7b19ca5b624ab80',
            'dev_requirement' => false,
        ),
        'joomla/di' => array(
            'pretty_version' => '1.5.1',
            'version' => '1.5.1.0',
            'type' => 'joomla-package',
            'install_path' => __DIR__ . '/../joomla/di',
            'aliases' => array(),
            'reference' => '33c66e4091e4433f33ddf4a0ac36604cf3b73c41',
            'dev_requirement' => false,
        ),
        'joomla/event' => array(
            'pretty_version' => '1.3.0',
            'version' => '1.3.0.0',
            'type' => 'joomla-package',
            'install_path' => __DIR__ . '/../joomla/event',
            'aliases' => array(),
            'reference' => 'ea97afdc7afd78cc9a0500f4b60372764fc2c0b0',
            'dev_requirement' => false,
        ),
        'joomla/filesystem' => array(
            'pretty_version' => '1.6.2',
            'version' => '1.6.2.0',
            'type' => 'joomla-package',
            'install_path' => __DIR__ . '/../joomla/filesystem',
            'aliases' => array(),
            'reference' => '9ad5d9b64960f0ea56fb71364a33622843b95c27',
            'dev_requirement' => false,
        ),
        'joomla/filter' => array(
            'pretty_version' => '1.4.4',
            'version' => '1.4.4.0',
            'type' => 'joomla-package',
            'install_path' => __DIR__ . '/../joomla/filter',
            'aliases' => array(),
            'reference' => '09733d70db6c6d91e53e0e0d0fcde9b8638175c4',
            'dev_requirement' => false,
        ),
        'joomla/image' => array(
            'pretty_version' => '1.5.1',
            'version' => '1.5.1.0',
            'type' => 'joomla-package',
            'install_path' => __DIR__ . '/../joomla/image',
            'aliases' => array(),
            'reference' => '00e843bccb2f9b1f1e6d8710ed55d103c641a75b',
            'dev_requirement' => false,
        ),
        'joomla/input' => array(
            'pretty_version' => '1.4.0',
            'version' => '1.4.0.0',
            'type' => 'joomla-package',
            'install_path' => __DIR__ . '/../joomla/input',
            'aliases' => array(),
            'reference' => 'a89927d412cdc8172889e3e0e3e66a134f367be1',
            'dev_requirement' => false,
        ),
        'joomla/joomla-cms' => array(
            'pretty_version' => 'dev-3.10-dev',
            'version' => 'dev-3.10-dev',
            'type' => 'project',
            'install_path' => __DIR__ . '/../../../',
            'aliases' => array(),
            'reference' => 'f4a39fcfe82e68162a5b12f3537f8d2c673c93f7',
            'dev_requirement' => false,
        ),
        'joomla/ldap' => array(
            'pretty_version' => '1.5.0',
            'version' => '1.5.0.0',
            'type' => 'joomla-package',
            'install_path' => __DIR__ . '/../joomla/ldap',
            'aliases' => array(),
            'reference' => '2b81fb2bb0a95b66d8aa1e3a4b6875990f5adf46',
            'dev_requirement' => false,
        ),
        'joomla/registry' => array(
            'pretty_version' => '1.6.4',
            'version' => '1.6.4.0',
            'type' => 'joomla-package',
            'install_path' => __DIR__ . '/../joomla/registry',
            'aliases' => array(),
            'reference' => '87450394f093efcb3ac5fc978e73d1403ebe8a38',
            'dev_requirement' => false,
        ),
        'joomla/session' => array(
            'pretty_version' => '1.6.0',
            'version' => '1.6.0.0',
            'type' => 'joomla-package',
            'install_path' => __DIR__ . '/../joomla/session/Joomla/Session',
            'aliases' => array(),
            'reference' => '0e1a0bd523bad42cae115f35e4079e5731a48d13',
            'dev_requirement' => false,
        ),
        'joomla/string' => array(
            'pretty_version' => '1.4.6',
            'version' => '1.4.6.0',
            'type' => 'joomla-package',
            'install_path' => __DIR__ . '/../joomla/string',
            'aliases' => array(),
            'reference' => '728ba9e39a8f1bd15b75ab878f57fa505184b8ab',
            'dev_requirement' => false,
        ),
        'joomla/uri' => array(
            'pretty_version' => '1.2.1',
            'version' => '1.2.1.0',
            'type' => 'joomla-package',
            'install_path' => __DIR__ . '/../joomla/uri',
            'aliases' => array(),
            'reference' => 'e3968e05d3b741378c106b44d8d72b230a43f845',
            'dev_requirement' => false,
        ),
        'joomla/utilities' => array(
            'pretty_version' => '1.6.2',
            'version' => '1.6.2.0',
            'type' => 'joomla-package',
            'install_path' => __DIR__ . '/../joomla/utilities',
            'aliases' => array(),
            'reference' => '9f7d9fda537ca005f7467de68f92506d48f348f5',
            'dev_requirement' => false,
        ),
        'leafo/lessphp' => array(
            'pretty_version' => 'dev-joomla3-php8',
            'version' => 'dev-joomla3-php8',
            'type' => 'library',
            'install_path' => __DIR__ . '/../leafo/lessphp',
            'aliases' => array(
                0 => '9999999-dev',
            ),
            'reference' => '802755b7632f59078843f38c9d57e5a8c496cc3a',
            'dev_requirement' => false,
        ),
        'paragonie/random_compat' => array(
            'pretty_version' => 'v1.4.3',
            'version' => '1.4.3.0',
            'type' => 'library',
            'install_path' => __DIR__ . '/../paragonie/random_compat',
            'aliases' => array(),
            'reference' => '9b3899e3c3ddde89016f576edb8c489708ad64cd',
            'dev_requirement' => false,
        ),
        'paragonie/sodium_compat' => array(
            'pretty_version' => 'v1.17.1',
            'version' => '1.17.1.0',
            'type' => 'library',
            'install_path' => __DIR__ . '/../paragonie/sodium_compat',
            'aliases' => array(),
            'reference' => 'ac994053faac18d386328c91c7900f930acadf1e',
            'dev_requirement' => false,
        ),
        'phpmailer/phpmailer' => array(
            'pretty_version' => 'dev-joomla-backports',
            'version' => 'dev-joomla-backports',
            'type' => 'library',
            'install_path' => __DIR__ . '/../phpmailer/phpmailer',
            'aliases' => array(
                0 => '9999999-dev',
            ),
            'reference' => '3bac61142e875279af98f16afef696b6bb7a19c9',
            'dev_requirement' => false,
        ),
        'psr/container' => array(
            'pretty_version' => '1.0.0',
            'version' => '1.0.0.0',
            'type' => 'library',
            'install_path' => __DIR__ . '/../psr/container',
            'aliases' => array(),
            'reference' => 'b7ce3b176482dbbc1245ebf52b181af44c2cf55f',
            'dev_requirement' => false,
        ),
        'psr/container-implementation' => array(
            'dev_requirement' => false,
            'provided' => array(
                0 => '~1.0',
            ),
        ),
        'psr/log' => array(
            'pretty_version' => '1.1.4',
            'version' => '1.1.4.0',
            'type' => 'library',
            'install_path' => __DIR__ . '/../psr/log',
            'aliases' => array(),
            'reference' => 'd49695b909c3b7628b6289db5479a1c204601f11',
            'dev_requirement' => false,
        ),
        'simplepie/simplepie' => array(
            'pretty_version' => '1.3.3',
            'version' => '1.3.3.0',
            'type' => 'library',
            'install_path' => __DIR__ . '/../simplepie/simplepie',
            'aliases' => array(),
            'reference' => '9f6fdaa79d9888ae8f1626b4f2e6b5ff7ca29bb3',
            'dev_requirement' => false,
        ),
        'symfony/polyfill-ctype' => array(
            'pretty_version' => 'v1.19.0',
            'version' => '1.19.0.0',
            'type' => 'library',
            'install_path' => __DIR__ . '/../symfony/polyfill-ctype',
            'aliases' => array(),
            'reference' => 'aed596913b70fae57be53d86faa2e9ef85a2297b',
            'dev_requirement' => false,
        ),
        'symfony/polyfill-php55' => array(
            'pretty_version' => 'v1.19.0',
            'version' => '1.19.0.0',
            'type' => 'library',
            'install_path' => __DIR__ . '/../symfony/polyfill-php55',
            'aliases' => array(),
            'reference' => '248a5c9877b126493abb661e4fb47792e418035b',
            'dev_requirement' => false,
        ),
        'symfony/polyfill-php56' => array(
            'pretty_version' => 'v1.19.0',
            'version' => '1.19.0.0',
            'type' => 'library',
            'install_path' => __DIR__ . '/../symfony/polyfill-php56',
            'aliases' => array(),
            'reference' => 'ea19621731cbd973a6702cfedef3419768bf3372',
            'dev_requirement' => false,
        ),
        'symfony/polyfill-php71' => array(
            'pretty_version' => 'v1.19.0',
            'version' => '1.19.0.0',
            'type' => 'library',
            'install_path' => __DIR__ . '/../symfony/polyfill-php71',
            'aliases' => array(),
            'reference' => '08aa78ab724f1264b3d1d32598c0c3e6903b7ab0',
            'dev_requirement' => false,
        ),
        'symfony/polyfill-php73' => array(
            'pretty_version' => 'v1.19.0',
            'version' => '1.19.0.0',
            'type' => 'library',
            'install_path' => __DIR__ . '/../symfony/polyfill-php73',
            'aliases' => array(),
            'reference' => '9d920e3218205554171b2503bb3e4a1366824a16',
            'dev_requirement' => false,
        ),
        'symfony/polyfill-util' => array(
            'pretty_version' => 'v1.19.0',
            'version' => '1.19.0.0',
            'type' => 'library',
            'install_path' => __DIR__ . '/../symfony/polyfill-util',
            'aliases' => array(),
            'reference' => '8df0c3e6a4b85df9a5c6f3f2f46fba5c5c47058a',
            'dev_requirement' => false,
        ),
        'symfony/yaml' => array(
            'pretty_version' => 'v2.8.52',
            'version' => '2.8.52.0',
            'type' => 'library',
            'install_path' => __DIR__ . '/../symfony/yaml',
            'aliases' => array(),
            'reference' => '02c1859112aa779d9ab394ae4f3381911d84052b',
            'dev_requirement' => false,
        ),
        'typo3/phar-stream-wrapper' => array(
            'pretty_version' => 'v2.2.2',
            'version' => '2.2.2.0',
            'type' => 'library',
            'install_path' => __DIR__ . '/../typo3/phar-stream-wrapper',
            'aliases' => array(),
            'reference' => 'cf7728109e0cab28da9ad357c3009e38d371116e',
            'dev_requirement' => false,
        ),
    ),
);
home/digilove/public_html/administrator/components/com_languages/models/installed.php000064400000024573152426642200025442 0ustar00<?php
/**
 * @package     Joomla.Administrator
 * @subpackage  com_languages
 *
 * @copyright   (C) 2009 Open Source Matters, Inc. <https://www.joomla.org>
 * @license     GNU General Public License version 2 or later; see LICENSE.txt
 */

defined('_JEXEC') or die;

use Joomla\Utilities\ArrayHelper;

/**
 * Languages Component Languages Model
 *
 * @since  1.6
 */
class LanguagesModelInstalled extends JModelList
{
	/**
	 * @var object client object
	 * @deprecated 4.0
	 */
	protected $client = null;

	/**
	 * @var object user object
	 */
	protected $user = null;

	/**
	 * @var boolean|JExeption True, if FTP settings should be shown, or an exception
	 */
	protected $ftp = null;

	/**
	 * @var string option name
	 */
	protected $option = null;

	/**
	 * @var array languages description
	 */
	protected $data = null;

	/**
	 * @var int total number of languages
	 */
	protected $total = null;

	/**
	 * @var int total number of languages installed
	 * @deprecated 4.0
	 */
	protected $langlist = null;

	/**
	 * @var string language path
	 */
	protected $path = null;

	/**
	 * Constructor.
	 *
	 * @param   array  $config  An optional associative array of configuration settings.
	 *
	 * @see     JController
	 * @since   3.5
	 */
	public function __construct($config = array())
	{
		if (empty($config['filter_fields']))
		{
			$config['filter_fields'] = array(
				'name',
				'nativeName',
				'language',
				'author',
				'published',
				'version',
				'creationDate',
				'author',
				'authorEmail',
				'extension_id',
				'client_id',
			);
		}

		parent::__construct($config);
	}

	/**
	 * 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   1.6
	 */
	protected function populateState($ordering = 'name', $direction = 'asc')
	{
		// Load the filter state.
		$this->setState('filter.search', $this->getUserStateFromRequest($this->context . '.filter.search', 'filter_search', '', 'string'));

		// Special case for client id.
		$clientId = (int) $this->getUserStateFromRequest($this->context . '.client_id', 'client_id', 0, 'int');
		$clientId = (!in_array($clientId, array (0, 1))) ? 0 : $clientId;
		$this->setState('client_id', $clientId);

		// Load the parameters.
		$params = JComponentHelper::getParams('com_languages');
		$this->setState('params', $params);

		// List state information.
		parent::populateState($ordering, $direction);
	}

	/**
	 * Method to get a store id based on model configuration state.
	 *
	 * This is necessary because the model is used by the component and
	 * different modules that might need different sets of data or different
	 * ordering requirements.
	 *
	 * @param   string  $id  A prefix for the store id.
	 *
	 * @return  string  A store id.
	 *
	 * @since   1.6
	 */
	protected function getStoreId($id = '')
	{
		// Compile the store id.
		$id	.= ':' . $this->getState('client_id');
		$id	.= ':' . $this->getState('filter.search');

		return parent::getStoreId($id);
	}

	/**
	 * Method to get the client object.
	 *
	 * @return  object
	 *
	 * @since   1.6
	 */
	public function getClient()
	{
		return JApplicationHelper::getClientInfo($this->getState('client_id', 0));
	}

	/**
	 * Method to get the ftp credentials.
	 *
	 * @return  object
	 *
	 * @since   1.6
	 */
	public function getFtp()
	{
		if (is_null($this->ftp))
		{
			$this->ftp = JClientHelper::setCredentialsFromRequest('ftp');
		}

		return $this->ftp;
	}

	/**
	 * Method to get the option.
	 *
	 * @return  object
	 *
	 * @since   1.6
	 */
	public function getOption()
	{
		$option = $this->getState('option');

		return $option;
	}

	/**
	 * Method to get Languages item data.
	 *
	 * @return  array
	 *
	 * @since   1.6
	 */
	public function getData()
	{
		// Fetch language data if not fetched yet.
		if (is_null($this->data))
		{
			$this->data = array();

			$isCurrentLanguageRtl = JFactory::getLanguage()->isRtl();
			$params               = JComponentHelper::getParams('com_languages');
			$installedLanguages   = JLanguageHelper::getInstalledLanguages(null, true, true, null, null, null);

			// Compute all the languages.
			foreach ($installedLanguages as $clientId => $languages)
			{
				$defaultLanguage = $params->get(JApplicationHelper::getClientInfo($clientId)->name, 'en-GB');

				foreach ($languages as $lang)
				{
					$row               = new stdClass;
					$row->language     = $lang->element;
					$row->name         = $lang->metadata['name'];
					$row->nativeName   = isset($lang->metadata['nativeName']) ? $lang->metadata['nativeName'] : '-';
					$row->client_id    = (int) $lang->client_id;
					$row->extension_id = (int) $lang->extension_id;
					$row->author       = $lang->manifest['author'];
					$row->creationDate = $lang->manifest['creationDate'];
					$row->authorEmail  = $lang->manifest['authorEmail'];
					$row->version      = $lang->manifest['version'];
					$row->published    = $defaultLanguage === $row->language ? 1 : 0;
					$row->checked_out  = 0;

					// Fix wrongly set parentheses in RTL languages
					if ($isCurrentLanguageRtl)
					{
						$row->name       = html_entity_decode($row->name . '&#x200E;', ENT_QUOTES, 'UTF-8');
						$row->nativeName = html_entity_decode($row->nativeName . '&#x200E;', ENT_QUOTES, 'UTF-8');
					}

					$this->data[] = $row;
				}
			}
		}

		$installedLanguages = array_merge($this->data);

		// Process filters.
		$clientId = (int) $this->getState('client_id');
		$search   = $this->getState('filter.search');

		foreach ($installedLanguages as $key => $installedLanguage)
		{
			// Filter by client id.
			if (in_array($clientId, array(0, 1)))
			{
				if ($installedLanguage->client_id !== $clientId)
				{
					unset($installedLanguages[$key]);
					continue;
				}
			}

			// Filter by search term.
			if (!empty($search))
			{
				if (stripos($installedLanguage->name, $search) === false
					&& stripos($installedLanguage->nativeName, $search) === false
					&& stripos($installedLanguage->language, $search) === false)
				{
					unset($installedLanguages[$key]);
					continue;
				}
			}
		}

		// Process ordering.
		$listOrder = $this->getState('list.ordering', 'name');
		$listDirn  = $this->getState('list.direction', 'ASC');
		$installedLanguages = ArrayHelper::sortObjects($installedLanguages, $listOrder, strtolower($listDirn) === 'desc' ? -1 : 1, true, true);

		// Process pagination.
		$limit = (int) $this->getState('list.limit', 25);

		// Sets the total for pagination.
		$this->total = count($installedLanguages);

		if ($limit !== 0)
		{
			$start = (int) $this->getState('list.start', 0);

			return array_slice($installedLanguages, $start, $limit);
		}

		return $installedLanguages;
	}

	/**
	 * Method to get installed languages data.
	 *
	 * @return  string	An SQL query.
	 *
	 * @since   1.6
	 *
	 * @deprecated   4.0
	 */
	protected function getLanguageList()
	{
		// Create a new db object.
		$db = $this->getDbo();
		$query = $db->getQuery(true);
		$client = $this->getState('client_id');
		$type = 'language';

		// Select field element from the extensions table.
		$query->select($this->getState('list.select', 'a.element'))
			->from('#__extensions AS a');

		$type = $db->quote($type);
		$query->where('(a.type = ' . $type . ')')
			->where('state = 0')
			->where('enabled = 1')
			->where('client_id=' . (int) $client);

		// For client_id = 1 do we need to check language table also?
		$db->setQuery($query);

		$this->langlist = $db->loadColumn();

		return $this->langlist;
	}

	/**
	 * Method to get the total number of Languages items.
	 *
	 * @return  integer
	 *
	 * @since   1.6
	 */
	public function getTotal()
	{
		if (is_null($this->total))
		{
			$this->getData();
		}

		return $this->total;
	}

	/**
	 * Method to set the default language.
	 *
	 * @param   integer  $cid  Id of the language to publish.
	 *
	 * @return  boolean
	 *
	 * @since   1.6
	 */
	public function publish($cid)
	{
		if ($cid)
		{
			$client = $this->getClient();

			$params = JComponentHelper::getParams('com_languages');
			$params->set($client->name, $cid);

			$table = JTable::getInstance('extension');
			$id    = $table->find(array('element' => 'com_languages'));

			// Load.
			if (!$table->load($id))
			{
				$this->setError($table->getError());

				return false;
			}

			$table->params = (string) $params;

			// Pre-save checks.
			if (!$table->check())
			{
				$this->setError($table->getError());

				return false;
			}

			// Save the changes.
			if (!$table->store())
			{
				$this->setError($table->getError());

				return false;
			}
		}
		else
		{
			$this->setError(JText::_('COM_LANGUAGES_ERR_NO_LANGUAGE_SELECTED'));

			return false;
		}

		// Clean the cache of com_languages and component cache.
		$this->cleanCache();
		$this->cleanCache('_system', 0);
		$this->cleanCache('_system', 1);

		return true;
	}

	/**
	 * Method to get the folders.
	 *
	 * @return  array  Languages folders.
	 *
	 * @since   1.6
	 */
	protected function getFolders()
	{
		if (is_null($this->folders))
		{
			$path = $this->getPath();
			jimport('joomla.filesystem.folder');
			$this->folders = JFolder::folders($path, '.', false, false, array('.svn', 'CVS', '.DS_Store', '__MACOSX', 'pdf_fonts', 'overrides'));
		}

		return $this->folders;
	}

	/**
	 * Method to get the path.
	 *
	 * @return  string	The path to the languages folders.
	 *
	 * @since   1.6
	 */
	protected function getPath()
	{
		if (is_null($this->path))
		{
			$client     = $this->getClient();
			$this->path = JLanguageHelper::getLanguagePath($client->path);
		}

		return $this->path;
	}

	/**
	 * Method to compare two languages in order to sort them.
	 *
	 * @param   object  $lang1  The first language.
	 * @param   object  $lang2  The second language.
	 *
	 * @return  integer
	 *
	 * @since   1.6
	 *
	 * @deprecated   4.0
	 */
	protected function compareLanguages($lang1, $lang2)
	{
		return strcmp($lang1->name, $lang2->name);
	}

	/**
	 * Method to switch the administrator language.
	 *
	 * @param   string  $cid  The language tag.
	 *
	 * @return  boolean
	 *
	 * @since   3.5
	 */
	public function switchAdminLanguage($cid)
	{
		if ($cid)
		{
			$client = $this->getClient();

			if ($client->name == 'administrator')
			{
				JFactory::getApplication()->setUserState('application.lang', $cid);
			}
		}
		else
		{
			JError::raiseWarning(500, JText::_('COM_LANGUAGES_ERR_NO_LANGUAGE_SELECTED'));

			return false;
		}

		return true;
	}
}