1. This site uses cookies. By continuing to use this site, you are agreeing to our use of cookies. Learn More.

XF 1.2 Help! Tried to run debug mode - site down.

Discussion in 'Troubleshooting and Problems' started by tommydamic68, Jan 20, 2014.

  1. tommydamic68

    tommydamic68 Well-Known Member

    Please help, I tried to run debug mode, added the code as the FAQ suggested above php>? and have this now. removed still have error.

    An exception occurred: Cannot send headers; headers already sent in /home1/admin/public_html/community/library/config.php, line 2 in /home1/admin/public_html/community/library/Zend/Controller/Response/Abstract.php on line 321

    1. Zend_Controller_Response_Abstract->canSendHeaders() in Zend/Controller/Response/Abstract.php at line 115
    2. Zend_Controller_Response_Abstract->setHeader() in XenForo/ViewRenderer/Abstract.php at line 63
    3. XenForo_ViewRenderer_Abstract->__construct() in XenForo/ViewRenderer/HtmlPublic.php at line 18
    4. XenForo_ViewRenderer_HtmlPublic->__construct() in XenForo/Dependencies/Public.php at line 212
    5. XenForo_Dependencies_Public->getViewRenderer() in XenForo/FrontController.php at line 547
    6. XenForo_FrontController->_getViewRenderer() in XenForo/FrontController.php at line 141
    7. XenForo_FrontController->run() in /home1/admin/public_html/community/index.php at line 13
  2. Chris D

    Chris D XenForo Developer Staff Member

    The FAQ absolutely does not advise you to add code above php>? least of all because that doesn't even appear in the config file.

    Your config file will look something like this:


    ['db']['host'] = '';
    $config['db']['port'] = '3306';
    $config['db']['username'] = 'root';
    $config['db']['password'] = '';
    $config['db']['dbname'] = '1_xenforo';

    $config['superAdmins'] = '1';

    $config['debug'] = true;
    But you will, of course, need to replace all of those db details with your own.
    tommydamic68 likes this.
  3. tommydamic68

    tommydamic68 Well-Known Member

    never mind - i got it back, where the heck do i add the
    $config['debug'] = true;
  4. tommydamic68

    tommydamic68 Well-Known Member

    lets try this again...
  5. MattW

    MattW Well-Known Member

    Put it where Chris has shown you above.
    tommydamic68 likes this.
  6. tommydamic68

    tommydamic68 Well-Known Member

    I did it successfully, thanks for the help fellas.
  7. JChandler

    JChandler Member

    Strangely, I set the following:

    $config['debug'] = 'false';

    and I'm still stuck in debug mode.

    I'm editing the library/config.php file - I've tried totally deleting the setting sort of assuming the default would go to "false"... that didn't work.

    Any clues (XF 1.2.5)
  8. Chris D

    Chris D XenForo Developer Staff Member

    What makes you think you are stuck in debug mode?

    Removing it should default it to switching debug mode off.

    Do you have any add-ons installed that may override the setting?

    The only other thing would be some sort of PHP file caching that isn't detecting that the file has changed, but check the other stuff out first.
  9. JChandler

    JChandler Member

    Well, the bottom of the forum index page has a link that leads to:


    and the developer option appears in the Admin CP. So I'm thinking I'm in debug mode.
  10. Chris D

    Chris D XenForo Developer Staff Member

    Yes, that's Debug mode.

    Do you have an add-on installed called Enable Debug From Admin Home?
  11. JChandler

    JChandler Member

    Nope: Donation Manager, KeyCaptcha, Member Search, Remove Gender, TAC AnyAPI, FoolBotHoneyPot, StopCountrySpam, and StopHumanSpam are all we're running.
  12. Chris D

    Chris D XenForo Developer Staff Member

    Could you paste here your config.php file (but please remove any passwords, database name etc.)
  13. JChandler

    JChandler Member

    OK... figured it out, somehow. I think it was a cached php config. It's off now. Weird.

Share This Page