PATH:
home
/
centosnipponia
/
public_html
/
nipponiacom2
/
components
/
com_djcatalog2
/
views
/
order
<?php /** * @version $Id: view.html.php 272 2014-05-21 10:25:49Z michal $ * @package DJ-Catalog2 * @copyright Copyright (C) 2012 DJ-Extensions.com LTD, All rights reserved. * @license http://www.gnu.org/licenses GNU/GPL * @author url: http://dj-extensions.com * @author email contact@dj-extensions.com * @developer Michal Olczyk - michal.olczyk@design-joomla.eu * * DJ-Catalog2 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-Catalog2 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-Catalog2. If not, see <http://www.gnu.org/licenses/>. * */ defined ('_JEXEC') or die('Restricted access'); jimport('joomla.application.component.view'); jimport('joomla.html.pagination'); class DJCatalog2ViewOrder extends JViewLegacy { public function __construct($config = array()) { parent::__construct($config); $this->_addPath('template', JPATH_COMPONENT. '/themes/default/views/order'); $theme = DJCatalog2ThemeHelper::getThemeName(); if ($theme && $theme != 'default') { $this->_addPath('template', JPATH_COMPONENT. '/themes/'.$theme.'/views/order'); } } public function display($tpl = null) { $app = JFactory::getApplication(); $user = JFactory::getUser(); $this->params = Djcatalog2Helper::getParams(); $this->state = $this->get('State'); $this->item = $this->get('Item'); if (empty($this->item)) { return JError::raiseError(404, JText::_('COM_DJCATALOG2_ORDER_NOT_FOUND')); return; } if ($user->guest) { $return_url = base64_encode(DJCatalogHelperRoute::getOrderRoute($this->item->id)); $app->redirect(JRoute::_('index.php?option=com_users&view=login&return='.$return_url, false), JText::_('COM_DJCATALOG2_PLEASE_LOGIN')); return true; } if ($user->id != $this->item->user_id) { return JError::raiseWarning(403, JText::_('JERROR_ALERTNOAUTHOR')); } $this->items = $this->item->items; // Check for errors. if (count($errors = $this->get('Errors'))) { JError::raiseError(500, implode("\n", $errors)); return false; } $this->_prepareDocument(); parent::display($tpl); } protected function _prepareDocument() { $app = JFactory::getApplication(); $menus = $app->getMenu(); $pathway = $app->getPathway(); $title = null; $heading = null; $menu = $menus->getActive(); $menu_query = (!empty($menu->query)) ? $menu->query : array(); $option = (!empty($menu_query['option'])) ? $menu_query['option'] : null; $view = (!empty($menu_query['view'])) ? $menu_query['view'] : null; $this->params->set('page_heading', JText::sprintf('COM_DJCATALOG2_ORDER_HEADING', $this->item->order_number)); $title = JText::sprintf('COM_DJCATALOG2_ORDER_HEADING', $this->item->order_number); if ($app->getCfg('sitename_pagetitles', 0)) { if ($app->getCfg('sitename_pagetitles', 0) == '2') { $title = JText::sprintf('JPAGETITLE', $title, $app->getCfg('sitename')); } else { $title = JText::sprintf('JPAGETITLE', $app->getCfg('sitename'), $title); } } $this->document->setTitle($title); } }
[+]
..
[-] index.html
[edit]
[+]
tmpl
[-] view.html.php
[edit]
[-] .htaccess.disabled
[edit]