Файловый менеджер - Редактировать - /var/www/iplanru/data/www/i-plan.ru/administrator/components/com_sef/controllers/extension.php
Назад
<?php /** * SEF component for Joomla! * * @package JoomSEF * @version 4.7.8 * @author ARTIO s.r.o., http://www.artio.net * @copyright Copyright (C) 2020 ARTIO s.r.o. * @license GNU/GPLv3 http://www.artio.net/license/gnu-general-public-license */ // Check to ensure this file is included in Joomla! defined('_JEXEC') or die(); class SEFControllerExtension extends SEFController { /** * constructor (registers additional tasks to methods) * @return void */ function __construct() { parent::__construct(); $this->registerTask('apply', 'save'); } function display($cachable = false, $urlparams = false) { JRequest::setVar('view', 'extensions'); parent::display(); } function save() { JRequest::checkToken() or jexit( 'Invalid Token' ); $task = JRequest::getCmd('task'); $file = JRequest::getVar('element'); $model = $this->getModel('extension'); if ($model->store()) { $msg = JText::_( 'Extension Saved' ); } else { $msg = JText::_( 'Error Saving Extension' ); } $redir = JRequest::getVar('redirto', ''); if( $task == 'save' ) { $link = 'index.php?option=com_sef'; if( !empty($redir) ) { $link .= '&'.$redir; } } elseif( $task == 'apply' ) { $link = 'index.php?option=com_sef&task=editext&cid[]='.$file; if( !empty($redir) ) { $link .= '&redirto='.urlencode($redir); } } $this->setRedirect($link, $msg); } function cancel() { $redir = JRequest::getVar('redirto', ''); $link = 'index.php?option=com_sef'; if( !empty($redir) ) { $link .= '&'.$redir; } $this->setRedirect($link); } function editId() { $model = $this->getModel('extension'); $view = $this->getView('extension', 'html', 'sefview'); $view->setModel($model, true); $view->showEditId(); } function saveId() { JRequest::checkToken() or jexit( 'Invalid Token' ); $model = $this->getModel('extension'); $model->storeId(); jexit(); } function changeHandler() { JRequest::checkToken() or jexit( 'Invalid Token' ); $model = $this->getModel('extension'); $msg = ''; if (!$model->changeHandler()) { $msg = 'Could not change handler'; } $redir = JRequest::getVar('redirto', ''); $link = 'index.php?option=com_sef'; if( !empty($redir) ) { $link .= '&'.$redir; } $this->setRedirect($link, $msg); } } ?>
| ver. 1.4 |
Github
|
.
| PHP 5.4.45-1~dotdeb+6.1 | Генерация страницы: 0.01 |
proxy
|
phpinfo
|
Настройка