I have been working for my new website for last couples of days. I have chosen the free template which is tk_gen_free_II downloaded from website http://themekat.com/. I have configured header and footer attaching all icons but I have started to add the articles in main contain I got such following message which appears just before article: Strict Standards: Non-static method JSite::getMenu() should not be called statically, assuming $this from incompatible context in C:\xampp\htdocs\joomla25\templates\tk_gen_free_ii\warp\systems\joomla\layouts\com_content\article\default.php on line 13 Strict Standards: Non-static method JApplication::getMenu() should not be called statically, assuming $this from incompatible context in C:\xampp\htdocs\joomla25\includes\application.php on line 539 and I don't know what to do now. Any suggestions?
I can not show the code because I run my website on local server. But I can copy longer bit of codes taken from those files This is the first part of code dealing with the first message: <?php /** * @package Warp Theme Framework * @author YOOtheme http://www.yootheme.com * @copyright Copyright (C) YOOtheme GmbH * @license http://www.gnu.org/licenses/gpl.html GNU/GPL */ // no direct access defined('_JEXEC') or die; // get view $menu = JSite::getMenu()->getActive(); //this that line 13 $view = is_object($menu) && isset($menu->query['view']) ? $menu->query['view'] : null; JHtml::addIncludePath(JPATH_COMPONENT . '/helpers'); // Create shortcuts to some parameters. $params = $this->item->params; $images = json_decode($this->item->images); $urls = json_decode($this->item->urls); $canEdit = $this->item->params->get('access-edit'); $user = JFactory::getUser(); And another part of code taken from the file dealing with second error message: * Return a reference to the JPathway object. * * @param string $name The name of the application/client. * @param array $options An optional associative array of configuration settings. * * @return object JMenu. * @since 1.5 */ public function getMenu($name = null, $options = array()) { $options = array(); $menu = parent::getMenu('site', $options); //This is line 539 return $menu; } /** * Return a reference to the JPathway object. * * @param string $name The name of the application. * @param array $options An optional associative array of configuration settings. * * @return object JPathway. * @since
I have partly solved this problem and I have switched off appearing error message Strict Standards. I have found that "Strict Standards" isn't technically an error, it's saying that the Joomla version you installed isn't strictly adhering to PHP standards. What you want to do is two things: first, restrict error reporting in php.ini to not report a standards violation as an error, then (when you're ready for go-live), turn off Joomla error reporting. In your php.ini, change error_reporting = E_ALL | E_STRICT to error_reporting = E_ALL & ~E_NOTICE If you have no access to server and file php.ini so there is another solution for this. Create .htaccess file with code: # supress php errors php_flag display_startup_errors off php_flag display_errors off php_flag html_errors off php_value docref_root 0 php_value docref_ext 0 and place that file in root joomla directory. And I have also noticed that that error message turns up only for free templates from http://themekat.com/ and does not come up with using other templates.