Source for file cancel.php

Documentation is available at cancel.php

  1. <?php
  2. /**
  3.  * @package     Joomla.Administrator
  4.  * @subpackage  com_config
  5.  *
  6.  * @copyright   Copyright (C) 2005 - 2013 Open Source Matters, Inc. All rights reserved.
  7.  * @license     GNU General Public License version 2 or later; see LICENSE.txt
  8.  */
  9.  
  10. defined('_JEXEC'or die;
  11.  
  12. /**
  13.  * Cancel Controller for global configuration
  14.  *
  15.  * @package     Joomla.Administrator
  16.  * @subpackage  com_config
  17.  * @since       3.2
  18.  */
  19. {
  20.     /**
  21.      * Method to cancel global configuration.
  22.      *
  23.      * @return  boolean  True on success.
  24.      *
  25.      * @since   3.2
  26.      */
  27.     public function execute()
  28.     {
  29.         // Check if the user is authorized to do this.
  30.         if (!JFactory::getUser()->authorise('core.admin''com_config'))
  31.         {
  32.             $this->app->enqueueMessage(JText::_('JERROR_ALERTNOAUTHOR'));
  33.             $this->app->redirect('index.php');
  34.         }
  35.  
  36.         $this->context = 'com_config.config.global';
  37.  
  38.         $this->redirect = 'index.php?option=com_cpanel';
  39.  
  40.         parent::execute();
  41.     }
  42. }

Documentation generated on Tue, 19 Nov 2013 14:55:01 +0100 by phpDocumentor 1.4.3