How to Fix Strict Standards: Non-static method in Joomla

How to Fix Strict Standards: Non-static method in Joomla

After installation of some  modules you might have experienced an error that occurs when PHP on their server is set to strict error reporting - where they receive error messages starting with phrases: “Strict Standards: Non-static methodon line XX”. Essentially, Strict Standards warnings are not really errors; they're messages designed for developers, but I fully agree they do not like nice on working Joomla site.

Those are two working solutions:

  • Method 1: In Joomla Back-end :  System -> Global Configuration, then click on the “Server” tab and find the Error Reporting parameters. Then set the Error Reporting setting to “None” and click on “Save” to keep the changes. See below screenshots...
  • 1. Log into Joomla

    How to add Google font into Joomla. Log in

    2. Go to System => Global Configuration

    How to fix Strict Standards in Joomla Global Configuration Server

    3. Set "None"

    How to fix Strict Standards in Joomla error reporting

  • Method 2: If above solution will not help, in root folder find php.ini file and inside edit line with "error_reporting"
    or
    create php.ini file and then inside put following code:
  • error_reporting = E_ALL & ~E_NOTICE & ~E_WARNING & ~E_STRICT & ~E_DEPRECATED
  • Method 3: Modify the template file. If two previous method is not available for you, we have the third way to fix Strict Standards: Non-static method.
  • error_reporting(0); (OR)
    ini_set('error_reporting', E_ALL & ~E_NOTICE & ~E_WARNING & ~E_STRICT & ~E_DEPRECATED);
    ini_set('display_errors','Off');