| Server IP : 54.36.91.62 / Your IP : 216.73.217.112 Web Server : Apache System : Linux webm013.cluster127.gra.hosting.ovh.net 5.15.206-ovh-vps-grsec-zfs-classid #1 SMP Fri May 15 02:41:25 UTC 2026 x86_64 User : coopiak ( 151928) PHP Version : 8.3.23 Disable Function : _dyuweyrj4,_dyuweyrj4r,dl MySQL : OFF | cURL : ON | WGET : ON | Perl : ON | Python : ON | Sudo : OFF | Pkexec : OFF Directory : /home/coopiak/amisdesseniors-fr/administrator/components/com_djcatalog2/controllers/ |
Upload File : |
<?php
/**
* @package DJ-Catalog2
* @copyright Copyright (C) DJ-Extensions.com, All rights reserved.
* @license http://www.gnu.org/licenses GNU/GPL
* @author url: http://dj-extensions.com
* @author email contact@dj-extensions.com
*/
defined('_JEXEC') or die;
use Joomla\CMS\Factory;
use Joomla\CMS\MVC\Controller\FormController;
use Joomla\CMS\Language\Text;
jimport('joomla.application.component.controllerform');
class Djcatalog2ControllerItem extends FormController {
function __construct($config = array())
{
$this->view_list = 'items';
$this->view_item = 'item';
parent::__construct($config);
}
function download() {
$app = Factory::getApplication();
$user = Factory::getUser();
$authorised = $user->authorise('djcatalog2.filedownload', 'com_djcatalog2');
if ($authorised !== true) {
throw new Joomla\CMS\MVC\View\GenericDataException(Text::_( 'JERROR_ALERTNOAUTHOR' ), 403);
}
if ($out = DJCatalog2FileHelper::getFile($app->input->get('fid','','int'))) {
$app->input->set('format','raw');
echo $out;
}
else {
throw new Joomla\CMS\MVC\View\GenericDataException(Text::_( 'COM_DJCATALOG2_NO_ITEM_SELECTED' ), 404);
}
}
}
?>