function display($tpl = null) { $app = JFactory::getApplication(); $params = $app->getParams(); $dispatcher = JDispatcher::getInstance(); $model = $this->getModel('addeditwalk'); $this->controller = JControllerLegacy::getInstance('SWG_WalkLibrary'); // Get some data from the models $state = $this->get('State'); $this->form = $this->get('Form'); $this->walk = $this->get('Walk'); // Check the current user can edit this walk (or add a new one) if ($model->editing() && !$this->controller->canEdit($this->walk) || !$model->editing() && !$this->controller->canAdd()) { return JError::raiseWarning(403, JText::_('JERROR_ALERTNOAUTHOR')); } // Check for errors. if (count($errors = $this->get('Errors'))) { JError::raiseError(500, implode('<br />', $errors)); return false; } $this->showForm = true; $this->editing = $model->editing(); // Display the view parent::display($tpl); }
function joooid_getController() { if (version_compare(JVERSION, '3.0', '<')) { return JController::getInstance('joooid'); } return JControllerLegacy::getInstance('joooid'); }
function display($tpl = null) { // Assign data to the view $this->walks = $this->get('Walks'); $this->controller = JControllerLegacy::getInstance('SWG_WalkLibrary'); // Check for errors. if (count($errors = $this->get('Errors'))) { JError::raiseError(500, implode('<br />', $errors)); return false; } // Set the template & title switch (JRequest::getInt("initialView")) { case 0: $this->pageTitle = "List walks"; $this->showList = true; $this->showSearch = false; $this->noWalkMsg = "No walks found"; break; case 1: // Get this leader's record // TODO: Integrate with Joomla users $leader = Leader::fromJoomlaUser(JFactory::getUser()->id); if ($leader == null) { $this->pageTitle = "Walks you've suggested"; $this->showList = true; $this->showSearch = false; $this->noWalkMsg = "Your leader account hasn't been set up properly. Please contact the vice chair or webmaster."; } else { $this->pageTitle = "Walks suggested by " . $leader->displayName; $this->showList = true; $this->showSearch = false; $this->noWalkMsg = "You haven't suggested any walks yet"; } break; case 2: $this->pageTitle = "Suggested walks"; $this->showList = true; $this->showSearch = false; $this->noWalkMsg = "No walks have been suggested"; break; case 3: default: $this->pageTitle = "Walks library"; $this->noWalkMsg = "No walks found"; if ($this->getModel()->hasWalkList()) { $this->showList = true; $this->showSearch = false; } else { $this->showList = false; $this->showSearch = true; } break; } // Set page heading. // TODO: Fix hack? JFactory::getApplication()->getMenu()->getActive()->params->set("page_heading", $this->pageTitle); // Display the view parent::display($tpl); }
public static function getCSS() { if (version_compare(JVERSION, '3.0', 'ge')) { $document = JFactory::getDocument(); $view = JRequest::getCmd('view', 'cpanel'); $document->addStyleSheet(JUri::base() . 'components/com_bt_portfolio/views/' . $view . '/tmpl/css/legacy.css'); return JControllerLegacy::getInstance('Bt_portfolio'); } }
public static function getCSS() { if (version_compare(JVERSION, '3.0', 'ge')) { $document = JFactory::getDocument(); $jinput = JFactory::getApplication()->input; $view = $jinput->get('view', 'cpanel', 'CMD'); $document->addStyleSheet(JUri::base() . 'components/com_bt_socialconnect/views/' . $view . '/tmpl/css/legacy.css'); return JControllerLegacy::getInstance('Bt_Socialconnect'); } }
public function onSloginCheck() { require_once JPATH_BASE . '/components/com_slogin/controller.php'; $controller = new SLoginController(); $input = JFactory::getApplication()->input; $error = $input->getString('error', ''); if ($error == 'access_denied') { $config = JComponentHelper::getParams('com_slogin'); JModel::addIncludePath(JPATH_ROOT . '/components/com_slogin/models'); $model = JModel::getInstance('Linking_user', 'SloginModel'); $redirect = base64_decode($model->getReturnURL($config, 'failure_redirect')); $controller = JControllerLegacy::getInstance('SLogin'); $controller->displayRedirect($redirect, true); } $request = null; $code = $input->get('code', null, 'STRING'); $returnRequest = new SloginRequest(); if ($code) { // get access_token from API $params = array('grant_type=authorization_code', 'code=' . $code, 'client_id=' . $this->params->get('id'), 'client_secret=' . $this->params->get('password')); $params = implode('&', $params); $url = 'https://oauth.yandex.ru/token'; $request = $controller->open_http($url, true, $params); $request = json_decode($request); if (!empty($request->error)) { echo 'Error - ' . $request->error; exit; } if (empty($request->access_token)) { echo 'Error - empty access tocken'; exit; } $url = 'https://login.yandex.ru/info?format=json&oauth_token=' . $request->access_token; $request = json_decode($controller->open_http($url)); if (empty($request)) { echo 'Error - empty user data'; exit; } $name = explode(' ', $request->real_name); $returnRequest->first_name = isset($name[1]) ? $name[1] : ''; $returnRequest->last_name = isset($name[0]) ? $name[0] : ''; $returnRequest->email = $request->default_email; $returnRequest->id = $request->id; $returnRequest->real_name = $request->real_name; $returnRequest->sex = $request->sex; $returnRequest->display_name = $request->display_name; $returnRequest->birthday = $request->birthday; $returnRequest->all_request = $request; return $returnRequest; } else { echo 'Error - empty code'; exit; } }
public function onSloginCheck() { $redirect = JURI::base() . '?option=com_slogin&task=check&plugin=linkedin'; $app = JFactory::getApplication(); $input = $app->input; $oauth_problem = $input->getString('oauth_problem', ''); if ($oauth_problem == 'user_refused') { $config = JComponentHelper::getParams('com_slogin'); JModel::addIncludePath(JPATH_ROOT . '/components/com_slogin/models'); $model = JModel::getInstance('Linking_user', 'SloginModel'); $redirect = base64_decode($model->getReturnURL($config, 'failure_redirect')); $controller = JControllerLegacy::getInstance('SLogin'); $controller->displayRedirect($redirect, true); } # First step is to initialize with your consumer key and secret. We'll use an out-of-band oauth_callback $linkedin = new LinkedIn($this->params->get('api_key'), $this->params->get('secret_key'), $redirect); //$linkedin->debug = true; $oauth_verifier = $input->getString('oauth_verifier', ''); $requestToken = unserialize($app->getUserState('requestToken')); $linkedin->request_token = $requestToken; $linkedin->oauth_verifier = $app->getUserState('oauth_verifier'); if (!empty($oauth_verifier)) { $app->setUserState('oauth_verifier', $oauth_verifier); $linkedin->getAccessToken($oauth_verifier); $app->setUserState('oauth_access_token', serialize($linkedin->access_token)); header("Location: " . $redirect); exit; } else { $linkedin->access_token = unserialize($app->getUserState('oauth_access_token')); } # You now have a $linkedin->access_token and can make calls on behalf of the current member //$request = $linkedin->getProfile("~:(id,first-name,last-name,headline,picture-url)"); $request = $linkedin->getProfile("~:(id,first-name,last-name,headline,picture-url,email-address)?format=json"); $request = json_decode($request); if (empty($request)) { echo 'Error - empty user data'; exit; } else { if (!empty($request->errorCode)) { echo 'Error - ' . $request->message; exit; } } $returnRequest = new SloginRequest(); $returnRequest->first_name = $request->firstName; $returnRequest->last_name = $request->lastName; // $returnRequest->email = $request->email; $returnRequest->id = $request->id; $returnRequest->real_name = $request->firstName . ' ' . $request->lastName; $returnRequest->display_name = $request->firstName; $returnRequest->all_request = $request; return $returnRequest; }
/** * Configure the Linkbar. */ public static function addSubmenu($vName = '') { JHtmlSidebar::addEntry(JText::_('COM_DZPRODUCT_TITLE_ITEMS'), 'index.php?option=com_dzproduct&view=items', $vName == 'items'); JHtmlSidebar::addEntry(JText::_('COM_DZPRODUCT_TITLE_CATEGORIES'), "index.php?option=com_categories&extension=com_dzproduct.items.catid", $vName == 'categories.items'); if ($vName == 'categories.items') { JToolBarHelper::title('DZ Products: Categories (Items - Item )'); // A hack to use our categories template instead of built-in categories template $controller = JControllerLegacy::getInstance('', 'CategoriesController'); $view = $controller->getView(); $view->addTemplatePath(JPATH_ADMINISTRATOR . '/components/com_dzproduct/views/categories/tmpl'); } JHtmlSidebar::addEntry(JText::_('COM_DZPRODUCT_TITLE_FIELDS'), 'index.php?option=com_dzproduct&view=fields', $vName == 'fields'); JHtmlSidebar::addEntry(JText::_('COM_DZPRODUCT_TITLE_GROUPS'), 'index.php?option=com_dzproduct&view=groups', $vName == 'groups'); JHtmlSidebar::addEntry(JText::_('COM_DZPRODUCT_TITLE_ORDERS'), 'index.php?option=com_dzproduct&view=orders', $vName == 'orders'); }
function display($tpl = null) { $app = JFactory::getApplication(); $params = $app->getParams(); $dispatcher = JDispatcher::getInstance(); $model = $this->getModel('walkdetails'); $controller = JControllerLegacy::getInstance('SWG_WalkLibrary'); // Get some data from the models $state = $this->get('State'); $this->walk = $this->get('Walk'); $this->walkInstances = $this->walk->getInstances(); // Get some permissions info $this->canAdd = $controller->canAdd(); $this->canEdit = $controller->canEdit($this->walk); // Check for errors. if (count($errors = $this->get('Errors'))) { JError::raiseError(500, implode('<br />', $errors)); return false; } // Load the map JS $document = JFactory::getDocument(); JHtml::_('behavior.framework', true); $document->addScript('/libraries/openlayers/OpenLayers.js'); $document->addScript('/swg/js/maps.js'); $start = new Waypoint(); $start->osRef = getOSRefFromSixFigureReference($this->walk->startGridRef); $end = new Waypoint(); $end->osRef = getOSRefFromSixFigureReference($this->walk->endGridRef); // Create the map $document->addScriptDeclaration(<<<MAP window.addEvent("domready", function() { \tvar map = new SWGMap('map'); \tvar walk = map.addWalk({$this->walk->id}); \tmap.addLoadedHandler(function() \t{ \t\tvar route = new Route(); \t\troute.load("walk", walk.id, 10, walk); \t\t//walk.loadRoute(map); // TODO: Should only load the most specific Route. Implement in other mapping pages. Detach route loading logic from walk object. \t}); }); MAP ); // Display the view parent::display($tpl); }
/** * Display the view */ public function display($tpl = null) { $doc = JFactory::getDocument(); $class = JRequest::getVar('class'); $method = JRequest::getVar('method'); if (!$class) { ApiError::raiseError(404, 'Class not found.'); } // Session // ================================================================= //$this->handleSession() ; // Excute method // ================================================================= $ctrl = JControllerLegacy::getInstance('Webgallery'); $model = $ctrl->getModel($class); if (!$model) { ApiError::raiseError(404, "Class: {$class} not exists."); return false; } if (!$method) { $method = $model->get('default_method', 'getItems'); } if (!is_callable(array($model, $method))) { ApiError::raiseError(404, "Method: {$class}::{$method} not exists."); return false; } $data = $model->{$method}(); // Check for errors. // ================================================================= if (count($errors = $this->get('Errors'))) { ApiError::raiseError(500, implode("\n", $errors)); return false; } // render Result // ================================================================= $result = new JObject(); $result->set('ApiResult', $data); if (JDEBUG) { $result->set('debug', ApiError::$debug); } echo $json = json_encode($result); return true; }
public function loadOtherTemplate($tpl = null, $layout, $view_name = null, array $vars = array()) { if (!empty($view_name)) { $controller = JControllerLegacy::getInstance(ucfirst($this->ext_name) . 'Controller' . ucfirst($view_name)); $view = $controller->getView($view_name, 'html'); $model = $controller->getModel($view_name); $current_layout = $this->getLayout(); $view->setModel($model, true); $view->setLayout($layout); foreach ($vars as $name => $var) { $view->assign($vars); } $html = $view->loadTemplate($tpl); $view->setLayout($current_layout); } else { $html = parent::loadTemplate($tpl); } return $html; }
/** * Render the application * * @return void */ public function render() { $document = JFactory::getDocument(); $config = JFactory::getConfig(); $user = JFactory::getUser(); switch ($document->getType()) { case 'html': // Set metadata $document->setTitle(JText::_('INSTL_PAGE_TITLE')); break; default: break; } // Define component path define('JPATH_COMPONENT', JPATH_BASE); define('JPATH_COMPONENT_SITE', JPATH_SITE); define('JPATH_COMPONENT_ADMINISTRATOR', JPATH_ADMINISTRATOR); // Start the output buffer. ob_start(); // Import the controller. require_once JPATH_COMPONENT . '/controller.php'; // Execute the task. $controller = JControllerLegacy::getInstance('JInstallation'); $controller->execute(JRequest::getVar('task')); $controller->redirect(); // Get output from the buffer and clean it. $contents = ob_get_contents(); ob_end_clean(); $file = JRequest::getCmd('tmpl', 'index'); $params = array('template' => 'template', 'file' => $file . '.php', 'directory' => JPATH_THEMES, 'params' => '{}'); $document->setBuffer($contents, 'installation'); $document->setTitle(JText::_('INSTL_PAGE_TITLE')); $data = $document->render(false, $params); JResponse::setBody($data); if (JFactory::getConfig()->get('debug_lang')) { $this->debugLanguage(); } }
public function __construct() { if (!php_Boot::$skip_constructor) { $GLOBALS['%s']->push("MainAdmin::new"); $__hx__spos = $GLOBALS['%s']->length; defined('_JEXEC') or die('no joomla here'); $gc = JControllerLegacy::getInstance('Joomlahaxe'); try { $gc->execute(JRequest::getCmd('task')); } catch (Exception $__hx__e) { $_ex_ = $__hx__e instanceof HException ? $__hx__e->e : $__hx__e; $e = $_ex_; $GLOBALS['%e'] = new _hx_array(array()); while ($GLOBALS['%s']->length >= $__hx__spos) { $GLOBALS['%e']->unshift($GLOBALS['%s']->pop()); } $GLOBALS['%s']->push($GLOBALS['%e'][0]); php_Lib::hprint($e); } $gc->redirect(); $GLOBALS['%s']->pop(); } }
<?php /** * @package Joomla.Administrator * @subpackage com_cpanel * * @copyright Copyright (C) 2005 - 2014 Open Source Matters, Inc. All rights reserved. * @license GNU General Public License version 2 or later; see LICENSE.txt */ defined('_JEXEC') or die; // No access check. $controller = JControllerLegacy::getInstance('Cpanel'); $controller->execute(JFactory::getApplication()->input->get('task')); $controller->redirect();
<?php // No direct access to this file defined('_JEXEC') or die('Restricted access'); // Get an instance of the controller prefixed by SoleilBlog $controller = JControllerLegacy::getInstance('SoleilBlog'); // Perform the Request task $controller->execute(JFactory::getApplication()->input->get('task')); // Redirect if set by the controller $controller->redirect();
<?php /** * @package Joomla.Administrator * @subpackage com_menus * @copyright Copyright (C) 2005 - 2012 Open Source Matters, Inc. All rights reserved. * @license GNU General Public License version 2 or later; see LICENSE.txt */ defined('_JEXEC') or die; // Access check. if (!JFactory::getUser()->authorise('core.manage', 'com_menus')) { return JError::raiseWarning(404, JText::_('JERROR_ALERTNOAUTHOR')); } // Execute the task. $controller = JControllerLegacy::getInstance('Menus'); $controller->execute(JRequest::getCmd('task')); $controller->redirect();
<?php // No direct access to this file defined('_JEXEC') or die('Restricted access'); // Set some global property $document = JFactory::getDocument(); // import joomla controller library jimport('joomla.application.component.controller'); // Get an instance of the controller prefixed by AdvancedOpenPortal $controller = JControllerLegacy::getInstance('AdvancedOpenPortal'); // Perform the Request task $controller->execute(JRequest::getCmd('task')); // Redirect if set by the controller $controller->redirect();
<?php /** * @version ##version## * @package joomla * @subpackage ##Component## * @author ##author## * @copyright Copyright (C) ##year##, ##author##. All rights reserved. * @license ##license## */ //--No direct access defined('_JEXEC') or die('Resrtricted Access'); require_once JPATH_COMPONENT . '/helpers/route.php'; $controller = JControllerLegacy::getInstance('##component##'); $controller->execute(JFactory::getApplication()->input->get('task')); $controller->redirect();
$plugins = JPluginHelper::getPlugin('system'); //wipe them out foreach ($plugins as $plugin) { $plugin->type = 'notToBeUsed'; //change type from system } $mainframe->initialise(); $mainframe->route(); /** * DISPATCH THE APPLICATION * * NOTE : */ $component_path = dirname(__FILE__); require_once $component_path . DS . 'controller.php'; if (class_exists('JControllerLegacy')) { $controller = JControllerLegacy::getInstance('Install', array('base_path' => $component_path)); } else { $controller = JController::getInstance('Install', array('base_path' => $component_path)); } $task = JRequest::getCmd('task', ''); ob_start(); $controller->execute($task); $controller->redirect(); $contents = ob_get_contents(); ob_end_clean(); ob_start(); $document = JFactory::getDocument(); $head = $document->getBuffer('head'); $head = '<html><head>' . $head . '</head>'; echo $head . '<body>' . $contents . '</body></html>';
<?php /** * @package Joomla.Administrator * @subpackage com_config * * @copyright Copyright (C) 2005 - 2012 Open Source Matters, Inc. All rights reserved. * @license GNU General Public License version 2 or later; see LICENSE.txt */ defined('_JEXEC') or die; // Access checks are done internally because of different requirements for the two controllers. // Tell the browser not to cache this page. JResponse::setHeader('Expires', 'Mon, 26 Jul 1997 05:00:00 GMT', true); $controller = JControllerLegacy::getInstance('Config'); $controller->execute(JFactory::getApplication()->input->get('task')); $controller->redirect();
<?php /** * @package Joomla.Site * @subpackage com_proveedor * * @copyright Copyright (C) 2005 - 2015 Open Source Matters, Inc. All rights reserved. * @license GNU General Public License version 2 or later; see LICENSE.txt */ defined('_JEXEC') or die; require_once JPATH_COMPONENT . '/helpers/route.php'; $controller = JControllerLegacy::getInstance('Proveedor'); $controller->execute(JFactory::getApplication()->input->get('task')); $controller->redirect();
<?php /* * @version 5.2.1 * @package JotCache * @category Joomla 3.4 * @copyright (C) 2010-2015 Vladimir Kanich * @license GNU General Public License version 2 or later */ defined('_JEXEC') or die('Restricted access'); $controller = JControllerLegacy::getInstance('Main'); $task = JFactory::getApplication()->input->get('task'); $controller->execute($task); $controller->redirect();
<?php /** * @package Joomla.Administrator * @subpackage com_messages * @copyright Copyright (C) 2005 - 2014 Open Source Matters, Inc. All rights reserved. * @license GNU General Public License version 2 or later; see LICENSE.txt */ defined('_HZEXEC_') or die; // Access check. if (!User::authorise('core.manage', 'com_messages')) { return App::abort(404, Lang::txt('JERROR_ALERTNOAUTHOR')); } $controller = JControllerLegacy::getInstance('Messages'); $controller->execute(Request::getCmd('task')); $controller->redirect();
* @copyright * @license GNU General Public License version 3 or later; See http://www.gnu.org/copyleft/gpl.html * * The following Component Architect header section must remain in any distribution of this file * * @CAversion Id: architectcomp.php 482 2015-04-06 17:48:54Z BrianWade $ * @CAauthor Component Architect (www.componentarchitect.com) * @CApackage architectcomp * @CAsubpackage architectcomp.admin * @CAtemplate joomla_3_4_standard (Release 1.0.0) * @CAcopyright Copyright (c)2013 - 2015 Simply Open Source Ltd. (trading as Component Architect). All Rights Reserved * @Joomlacopyright Copyright (c)2005 - 2015 Open Source Matters, Inc. All rights reserved. * @CAlicense GNU General Public License version 3 or later; See http://www.gnu.org/copyleft/gpl.html * * This program is free software: you can redistribute it and/or modify it under the terms of the GNU General Public License as published by * the Free Software Foundation, either version 3 of the License, or (at your option) any later version. * * This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details. */ defined('_JEXEC') or die; JHtml::_('behavior.tabstate'); // Access check. if (!JFactory::getUser()->authorise('core.manage', 'com_knvbapi')) { return JError::raiseWarning(404, JText::_('JERROR_ALERTNOAUTHOR')); } // Include dependancies JLoader::register('KnvbapiHelper', __DIR__ . '/helpers/knvbapi.php'); $controller = JControllerLegacy::getInstance('knvbapi'); $controller->execute(JFactory::getApplication()->input->get('task')); $controller->redirect();
<?php /** * @package Joomla.Administrator * @subpackage com_modules * @copyright Copyright (C) 2005 - 2013 Open Source Matters, Inc. All rights reserved. * @license GNU General Public License version 2 or later; see LICENSE.txt */ defined('_JEXEC') or die; // Access check. if (!JFactory::getUser()->authorise('core.manage', 'com_modules')) { return JError::raiseWarning(404, JText::_('JERROR_ALERTNOAUTHOR')); } $controller = JControllerLegacy::getInstance('Modules'); $controller->execute(JRequest::getCmd('task')); $controller->redirect();
* @developer Szymon Woronowski - szymon.woronowski@design-joomla.eu * * * DJ-ImageSlider is free software: you can redistribute it and/or modify * it under the terms of the GNU General Public License as published by * the Free Software Foundation, either version 3 of the License, or * (at your option) any later version. * * DJ-ImageSlider is distributed in the hope that it will be useful, * but WITHOUT ANY WARRANTY; without even the implied warranty of * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the * GNU General Public License for more details. * * You should have received a copy of the GNU General Public License * along with DJ-ImageSlider. If not, see <http://www.gnu.org/licenses/>. * */ // no direct access defined('_JEXEC') or die('Restricted access'); defined('DS') or define('DS', DIRECTORY_SEPARATOR); // Include dependancies jimport('joomla.application.component.controller'); $db = JFactory::getDBO(); $db->setQuery("SELECT manifest_cache FROM #__extensions WHERE element='com_djimageslider' LIMIT 1"); $version = json_decode($db->loadResult()); $version = $version->version; define('DJIMAGESLIDERFOOTER', '<div style="text-align: center; margin: 10px 0;">DJ-ImageSlider (version ' . $version . '), © 2010-' . JFactory::getDate()->format('Y') . ' Copyright by <a target="_blank" href="http://dj-extensions.com">DJ-Extensions.com</a>, All Rights Reserved.<br /><a target="_blank" href="http://dj-extensions.com"><img src="' . JURI::base() . 'components/com_djimageslider/assets/logo.png" alt="DJ-Extensions.com" style="margin: 20px 0 0;" /></a></div>'); $controller = JControllerLegacy::getInstance('djimageslider'); // Perform the Request task $controller->execute(JFactory::getApplication()->input->get('task')); $controller->redirect();
<?php /** * @package EmailTemplates * @subpackage Component * @author Todor Iliev * @copyright Copyright (C) 2016 Todor Iliev <*****@*****.**>. All rights reserved. * @license GNU General Public License version 3 or later; see LICENSE.txt */ // no direct access defined('_JEXEC') or die; jimport('Prism.init'); jimport('Emailtemplates.init'); // Get an instance of the controller prefixed by HelloWorld $controller = JControllerLegacy::getInstance('EmailTemplates'); // Perform the Request task $controller->execute(JFactory::getApplication()->input->getCmd('task')); $controller->redirect();
<?php /** * @package Projectfork * @subpackage Forum * * @author Tobias Kuhn (eaxs) * @copyright Copyright (C) 2006-2012 Tobias Kuhn. All rights reserved. * @license http://www.gnu.org/licenses/gpl.html GNU/GPL, see LICENSE.txt */ defined('_JEXEC') or die; // Access check if (!JFactory::getUser()->authorise('core.manage', 'com_pfforum')) { return JError::raiseWarning(403, JText::_('JERROR_ALERTNOAUTHOR')); } // Include dependencies jimport('joomla.application.component.controller'); jimport('joomla.application.component.helper'); jimport('projectfork.framework'); // Register classes to autoload JLoader::register('PFforumHelper', JPATH_ADMINISTRATOR . '/components/com_pfforum/helpers/pfforum.php'); JHtml::addincludepath(JPATH_ADMINISTRATOR . '/components/com_pfforum/helpers/html'); $controller = JControllerLegacy::getInstance('PFforum'); $controller->execute(JFactory::getApplication()->input->get('task')); $controller->redirect();
<?php ini_set('display_errors', true); error_reporting(E_ALL); defined('_JEXEC') or die('Acces Deny'); jimport('joomla.application.component.controller'); $controller = JControllerLegacy::getInstance('Absolventi'); $controller->execute(JFactory::getApplication()->input->getCmd('task')); $controller->redirect();
<?php /** * @package Joomla.Administrator * @subpackage com_content * @copyright Copyright (C) 2005 - 2014 Open Source Matters, Inc. All rights reserved. * @license GNU General Public License version 2 or later; see LICENSE.txt */ defined('_JEXEC') or die; // Access check. if (!JFactory::getUser()->authorise('core.manage', 'com_content')) { return JError::raiseWarning(404, JText::_('JERROR_ALERTNOAUTHOR')); } // Register helper class JLoader::register('ContentHelper', dirname(__FILE__) . '/helpers/content.php'); $controller = JControllerLegacy::getInstance('Content'); $controller->execute(JRequest::getCmd('task')); $controller->redirect();