Jump to content

DEBUG- Cannot modify header information ?


Recommended Posts

Hi, If I turn on debug mode I get the following error showing in B.O

 

Warning on line 1761 in file /home/******/public_html/classes/controller/AdminController.php
[2] Cannot modify header information - headers already sent by (output started at /home/******/public_html/config/config.inc.php:61)

 

Any ideas what this can be ?

 

Some modules arent working correctly, one being the loyalts rewards.

I cannot configure it, ie when trying to choose the radio buttons for categories, when clicking the 1st one the page automatically refreshes, tries to save, and says no category selected.I cannot multi select or save :(

 

 

1761 in my AdminController says

 

header('Cache-Control: no-store, no-cache');

Edited by MerseyRay (see edit history)
Link to comment
Share on other sites

Plus, front office on the homepage I get this

 

Notice: Use of undefined constant _PS_CUSTOM_CONFIG_FILE_ - assumed '_PS_CUSTOM_CONFIG_FILE_' in /home/******/public_html/config/config.inc.php on line 61

Warning: Cannot modify header information - headers already sent by (output started at /home/nomatchc/public_html/config/config.inc.php:61) in /home//******//public_html/classes/controller/FrontController.php on line 996

Warning: Cannot modify header information - headers already sent by (output started at /home/nomatchc/public_html/config/config.inc.php:61) in /home//******//public_html/classes/controller/FrontController.php on line 997

Link to comment
Share on other sites

If I comment out the line 61 onwards then it doesnt show the error.

Im not using any custom config that im aware of.

 

/* Custom config made by users
if (is_file(_PS_CUSTOM_CONFIG_FILE_))
    include_once(_PS_CUSTOM_CONFIG_FILE_);*/

 

Is that problem sorted or will this cause issues ?

Link to comment
Share on other sites

Oh, and clicking on an order I get this error message (Only when debug is turned on)

[PrestaShopDatabaseException]

Table ******.ps_paypal_capture' doesn't exist

SELECT SUM(capture_amount)
FROM `ps_paypal_capture`
WHERE (id_order = 13330) AND (result = "Completed") LIMIT 1

at line 765 in file classes/db/Db.php

760. 			WebserviceRequest::getInstance()->setError(500, '[SQL Error] '.$this->getMsgError().'. From '.(isset($dbg[3]['class']) ? $dbg[3]['class'] : '').'->'.$dbg[3]['function'].'() Query was : '.$sql, 97);
761. 		}
762. 		elseif (_PS_DEBUG_SQL_ && $errno && !defined('PS_INSTALLATION_IN_PROGRESS'))
763. 		{
764. 			if ($sql)
765. 				throw new PrestaShopDatabaseException($this->getMsgError().'<br /><br /><pre>'.$sql.'</pre>');
766. 
767. 			throw new PrestaShopDatabaseException($this->getMsgError());
768. 		}
769. 	}
770. 

    DbCore->displayError - [line 418 - classes/db/Db.php] - [1 Arguments]
    DbCore->query - [line 669 - classes/db/Db.php] - [1 Arguments]
    DbCore->getRow - [line 698 - classes/db/Db.php] - [2 Arguments]
    DbCore->getValue - [line 117 - modules/paypal/classes/PaypalCapture.php] - [1 Arguments]
    PaypalCapture::getTotalAmountCapturedByIdOrder - [line 126 - modules/paypal/classes/PaypalCapture.php] - [1 Arguments]
    PaypalCapture->getRestToPaid - [line 749 - modules/paypal/paypal.php] - [1 Arguments]
    PayPal->hookAdminOrder - [line 569 - classes/Hook.php] - [1 Arguments]
    HookCore::coreCallHook - [line 526 - classes/Hook.php] - [3 Arguments]
    HookCore::exec - [line 197 - config/smarty.config.inc.php] - [3 Arguments]
Edited by MerseyRay (see edit history)
Link to comment
Share on other sites

  • 2 weeks later...

Interesting, saw this error today after installing an SEO mod, modules BO. No issues front end however:

 

line 1761../classes/controller/AdminController.php
[2] Cannot modify header information - headers already sent by (output started at

Link to comment
Share on other sites

  • 8 months later...

Okay, apparently I have this error too, I just noticed it while clicking on "read more" for one of the not installed modules in the BO. It doesn't look like there are errors in the FO or BO, except for that.

 

Should I ignore it, or is it a symptom of a deeper problem and should be addressed?

Link to comment
Share on other sites

×
×
  • Create New...