Source for file view.html.php

Documentation is available at view.html.php

  1. <?php
  2. /**
  3.  * @package     Joomla.Administrator
  4.  * @subpackage  com_cpanel
  5.  *
  6.  * @copyright   Copyright (C) 2005 - 2013 Open Source Matters, Inc. All rights reserved.
  7.  * @license     GNU General Public License version 2 or later; see LICENSE.txt
  8.  */
  9.  
  10. defined('_JEXEC'or die;
  11.  
  12. /**
  13.  * HTML View class for the Cpanel component
  14.  *
  15.  * @package     Joomla.Administrator
  16.  * @subpackage  com_cpanel
  17.  * @since       1.0
  18.  */
  19. class CpanelViewCpanel extends JViewLegacy
  20. {
  21.     /**
  22.      * Array of cpanel modules
  23.      *
  24.      * @var  array 
  25.      */
  26.     protected $modules = null;
  27.  
  28.     /**
  29.      * Execute and display a template script.
  30.      *
  31.      * @param   string  $tpl  The name of the template file to parse; automatically searches through the template paths.
  32.      *
  33.      * @return  mixed  A string if successful, otherwise a Error object.
  34.      */
  35.     public function display($tpl null)
  36.     {
  37.         // Set toolbar items for the page
  38.         JToolbarHelper::title(JText::_('COM_CPANEL')'home-2 cpanel');
  39.         JToolbarHelper::help('screen.cpanel');
  40.  
  41.         $input JFactory::getApplication()->input;
  42.  
  43.         /*
  44.          * Set the template - this will display cpanel.php
  45.          * from the selected admin template.
  46.          */
  47.         $input->set('tmpl''cpanel');
  48.  
  49.         // Display the cpanel modules
  50.         $this->modules = JModuleHelper::getModules('cpanel');
  51.  
  52.         // Load the RAD layer and count the number of post-installation messages
  53.         if (!defined('FOF_INCLUDED'))
  54.         {
  55.             require_once JPATH_LIBRARIES '/fof/include.php';
  56.         }
  57.  
  58.         $messages_model FOFModel::getTmpInstance('Messages''PostinstallModel'array('input' => array('eid' => 700)));
  59.         $messages $messages_model->getItemList();
  60.  
  61.         $this->postinstall_message_count count($messages);
  62.  
  63.         parent::display($tpl);
  64.     }
  65. }

Documentation generated on Tue, 19 Nov 2013 15:17:15 +0100 by phpDocumentor 1.4.3