Support » Plugin: WP Debugging » Error upon plugin activation : register_sidebar was called incorrectly

  • Resolved Agent 002


    Hi Andy,

    I’ve read welcome post, searched forum, updated theme and almost all plugins.

    I would like to install this plugin on my production environment to assist another plugin to debug something, however I’ve installed it on my pre-production site and it has immediately thrown an error on the BE below header, but BE still functions and the error is shown on FE then FE breaks. Once deactivated and caches cleared the error is gone and FE is OK.

    The error is as follows:

    Notice: register_sidebar was called incorrectly. No id was set in the arguments array for the “Sidebar 1” sidebar. Defaulting to “sidebar-1”. Manually set the id to “sidebar-1” to silence this notice and keep existing sidebar content. Please see Debugging in WordPress for more information. (This message was added in version 4.2.0.) in /home/hnlpreprodthebro/public_html/wp-includes/functions.php on line 5313

    I’ve looked up the error on other forums and CAN find a solution, but I’m not sure why it should be necessary to make the code changes outlined in those solutions for this plugin to function. I very well may be incorrect.

    I’m perhaps thinking it may be something to do with the .htaccess file in the same directory as the wp-config file as I’ve added the code below as a security measure.
    <files wp-config.php>
    order allow,deny
    deny from all

    Browser Chrome up to date
    OS Windows 10
    Wordpress version 5.7.1
    Litespeed Server/Cache

    The page I need help with: [log in to see the link]

Viewing 3 replies - 1 through 3 (of 3 total)
  • Plugin Author Andy Fragen


    Because WP Debugging has set certain constants, these error messages are visible. If you uncheck the display messages setting they should just go to the debug.log

    Unfortunately the error is in your theme.

    Thread Starter Agent 002


    Hi Andy,

    Do you mean to Check
    Set WP_DEBUG_DISPLAY to false, default is true?
    I have tried that, purged caches and it has not made any difference.

    I appreciate this very well may be an issue with the theme, but why is it breaking the FE of the pre-production site when while wp-debugging plugin is deactivated everything works correctly?

    ANy help would be appreciated.

    Plugin Author Andy Fragen


    WP Debugging just sets constants in the WP-config.php file. It is done to surface errors in code.

    Switch to a default theme to demonstrate that the errors go away.

Viewing 3 replies - 1 through 3 (of 3 total)
  • You must be logged in to reply to this topic.