CoreFiles by mySites.guru
fields.php30 lines, 948 bytes, from Joomla_3.9.14-Stable-Full_Package.zip
Raw History Compare with 3.9.13
md5
245ef4cbedd49e7f16b7d60b6b5210af
sha1
c6736006a98cc0ee558a6b6cf3b4320e0c756652
sha256
0a30552861abe095f579165e41317274b449c765cb0e4762dae6a9d712686265
<?php
/**
 * @package     Joomla.Administrator
 * @subpackage  com_fields
 *
 * @copyright   Copyright (C) 2005 - 2019 Open Source Matters, Inc. All rights reserved.
 * @license     GNU General Public License version 2 or later; see LICENSE.txt
 */
defined('_JEXEC') or die;

JLoader::register('FieldsHelper', JPATH_ADMINISTRATOR . '/components/com_fields/helpers/fields.php');

$app       = JFactory::getApplication();
$context   = $app->getUserStateFromRequest(
	'com_fields.groups.context',
	'context',
	$app->getUserStateFromRequest('com_fields.fields.context', 'context', 'com_content.article', 'CMD'),
	'CMD'
);

$parts = FieldsHelper::extract($context);

if (!$parts || !JFactory::getUser()->authorise('core.manage', $parts[0]))
{
	throw new JAccessExceptionNotallowed(JText::_('JERROR_ALERTNOAUTHOR'), 403);
}

$controller = JControllerLegacy::getInstance('Fields');
$controller->execute($app->input->get('task'));
$controller->redirect();

The same content is in 26 releases, Joomla 3.9.2-rc to 3.9.14. See them all, or every version of this file.