- md5
- 3a57912a69a5439a9bd1bfabc0810163
- sha1
- 532590c07424da8428ed62b6aaee3cc9dddde397
- sha256
- 61e0586563ce408ebcf031590e502c80c8f0ea61d2f2b762a36f23cfaa49f27b
12345678910111213141516171819202122232425262728293031323334353637383940414243444546474849505152535455565758596061626364656667
<?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 controller Class.
*
* @since 1.6
*/
class LanguagesControllerLanguages extends JControllerAdmin
{
/**
* Method to get a model object, loading it if required.
*
* @param string $name The model name. Optional.
* @param string $prefix The class prefix. Optional.
* @param array $config Configuration array for model. Optional.
*
* @return object The model.
*
* @since 1.6
*/
public function getModel($name = 'Language', $prefix = 'LanguagesModel', $config = array('ignore_request' => true))
{
return parent::getModel($name, $prefix, $config);
}
/**
* Method to save the submitted ordering values for records via AJAX.
*
* @return void
*
* @since 3.1
*/
public function saveOrderAjax()
{
$pks = $this->input->post->get('cid', array(), 'array');
$order = $this->input->post->get('order', array(), 'array');
// Sanitize the input.
$pks = ArrayHelper::toInteger($pks);
$order = ArrayHelper::toInteger($order);
// Get the model.
$model = $this->getModel();
// Save the ordering.
$return = $model->saveorder($pks, $order);
if ($return)
{
echo '1';
}
// Close the application.
JFactory::getApplication()->close();
}
}
The same content is in 2 releases, Joomla 3.10.0-alpha2 to 3.10.0-alpha3. See them all, or every version of this file.