Source for file update.php
Documentation is available at update.php
* @package Joomla.Administrator
* @subpackage com_installer
* @copyright Copyright (C) 2005 - 2013 Open Source Matters, Inc. All rights reserved.
* @license GNU General Public License version 2 or later; see LICENSE.txt
* Installer Update Controller
* @package Joomla.Administrator
* @subpackage com_installer
* Update a set of extensions.
// Check for request forgeries
$uid =
$this->input->get('cid', array(), 'array');
if ($model->update($uid))
$redirect_url =
$app->getUserState('com_installer.redirect_url');
if (empty($redirect_url))
$redirect_url =
JRoute::_('index.php?option=com_installer&view=update', false);
// Wipe out the user state when we're going to redirect
$app->setUserState('com_installer.redirect_url', '');
$app->setUserState('com_installer.message', '');
$app->setUserState('com_installer.extension_message', '');
// Check for request forgeries
// Get the caching duration
$params =
$component->params;
$cache_timeout =
$params->get('cachetimeout', 6, 'int');
$cache_timeout =
3600 *
$cache_timeout;
$model->findUpdates(0, $cache_timeout);
// Check for request forgeries
$this->setRedirect(JRoute::_('index.php?option=com_installer&view=update', false), $model->_message);
* Fetch and report updates in JSON format, for AJAX requests
* Note: we don't do a token check as we're fetching information
* asynchronously. This means that between requests the token might
* change, making it impossible for AJAX to work.
$eid =
$this->input->getInt('eid', 0);
$skip =
$this->input->get('skip', array(), 'array');
$cache_timeout =
$this->input->getInt('cache_timeout', 0);
$params =
$component->params;
$cache_timeout =
$params->get('cachetimeout', 6, 'int');
$cache_timeout =
3600 *
$cache_timeout;
$model->findUpdates($eid, $cache_timeout);
$model->setState('list.start', 0);
$model->setState('list.limit', 0);
$model->setState('filter.extension_id', $eid);
$updates =
$model->getItems();
$unfiltered_updates =
$updates;
foreach ($unfiltered_updates as $update)
if (!in_array($update->extension_id, $skip))
Documentation generated on Tue, 19 Nov 2013 15:16:11 +0100 by phpDocumentor 1.4.3