How do I hide a notice or warning in WordPress?

Collapse

Unconfigured Ad Widget

Collapse
X
 
  • Filter
  • Time
  • Show
Clear All
new posts
  • Clay Page
    Member
    • Sep 2022
    • 89

    How do I hide a notice or warning in WordPress?

    Hello everyone,

    I'm in search of advice and methods to hide notices or warnings in WordPress. If you have experience or insights on this matter and can help answer my questions, your assistance would be greatly appreciated.
  • Rex Maughan
    Senior Member
    • Mar 2022
    • 124

    #2
    PHP warnings and notices should be distinct from the internal server, syntax, or fatal errors, which can disrupt your website's functionality. In most cases, warnings and notices are not cause for concern on a production site. However, plugin or theme developers need to be aware of them so that they can address these issues in future releases.


    Step 1: Log into your CPanel account.
    Step 2: Scroll down to Files and choose File Manager.





    Step 3: Inside the public_html directory, find the wp-config.php file.
    Step 4: Right-click on it and choose the Edit option.





    Step 5: Inside the wp-config.php file, look for the following:
    define('WP_DEBUG', false);

    Step 6: Replace it with the following code:

    ini_set('display_errors,''Off');
    ini_set('error_reporting', E_ALL );
    define('WP_DEBUG', false);
    define('WP_DEBUG_DISPLAY', false);


    Step 7: Click on Save Changes.












    Comment

    Working...
    X