prestashopuser01 Posted May 19, 2014 Share Posted May 19, 2014 Help required folks. Am trying to edit products in the BE. I can see the products in the BE, but when I click on edit I get a blank page. Enabled error logging and am getting the below error message : "Constant __PS_BASE_URI__ already defined in /hermes/bosoraweb165/b331/ipg.pcptunes/prestashop/config/config.inc.php on line 105" Prestashop Version : 1.5.6.2 Link to comment Share on other sites More sharing options...
NemoPS Posted May 19, 2014 Share Posted May 19, 2014 Are you using any product-related third party module? One of them might be causing the config file being included 2 times Link to comment Share on other sites More sharing options...
prestashopuser01 Posted May 19, 2014 Author Share Posted May 19, 2014 Nope I have never installed any third party module. Its all the default modules which came with the installation. Anything else you want me to look for clues. ? Link to comment Share on other sites More sharing options...
phew72 Posted June 11, 2014 Share Posted June 11, 2014 Hi. Not sure if you've solved this is not, but I have the exact same problem. I've managed to remove the error message by commenting out the following line in the config/config.inc.php file (line 105): // define('__PS_BASE_URI__', $context->shop->getBaseURI()); So the error reporting is now clean, and everything seems to be working. I doubt this is good practice though, in fact I'd love to know how to fix it properly. Link to comment Share on other sites More sharing options...
NemoPS Posted June 11, 2014 Share Posted June 11, 2014 That is not good practice of course, there must be a module currently implementing the config file on it's own, are you maybe able to find the string anywhere else in the main folder/subfolders? Link to comment Share on other sites More sharing options...
phew72 Posted June 11, 2014 Share Posted June 11, 2014 Hi Nemo The error msg on the front-end pages is: Notice: Constant __PS_BASE_URI__ already defined in /var/www/vhosts/1/127061/webspace/httpdocs/config/config.inc.php on line 105 Call Stack: 0.0064 234952 1. {main}() /var/www/vhosts/1/127061/webspace/httpdocs/index.php:0 0.0085 300544 2. require('/var/www/vhosts/1/127061/webspace/httpdocs/config/config.inc.php') /var/www/vhosts/1/127061/webspace/httpdocs/index.php:27 0.1043 2496024 3. define() /var/www/vhosts/1/127061/webspace/httpdocs/config/config.inc.php:105 Warning: Cannot modify header information - headers already sent by (output started at /var/www/vhosts/1/127061/webspace/httpdocs/config/config.inc.php:105) in /var/www/vhosts/1/127061/webspace/httpdocs/classes/controller/FrontController.php on line 756 Call Stack: 0.0064 234952 1. {main}() /var/www/vhosts/1/127061/webspace/httpdocs/index.php:0 0.2647 6038224 2. DispatcherCore->dispatch() /var/www/vhosts/1/127061/webspace/httpdocs/index.php:28 0.3010 6609088 3. ControllerCore->run() /var/www/vhosts/1/127061/webspace/httpdocs/classes/Dispatcher.php:348 0.3834 9960432 4. FrontControllerCore->initHeader() /var/www/vhosts/1/127061/webspace/httpdocs/classes/controller/Controller.php:164 0.3834 9960600 5. header() /var/www/vhosts/1/127061/webspace/httpdocs/classes/controller/FrontController.php:756 On the back-end pages it's: Notice: Constant __PS_BASE_URI__ already defined in /var/www/vhosts/1/127061/webspace/httpdocs/config/config.inc.php on line 105 Call Stack: 0.0023 245168 1. {main}() /var/www/vhosts/1/127061/webspace/httpdocs/admin8254/index.php:0 0.0107 311240 2. require('/var/www/vhosts/1/127061/webspace/httpdocs/config/config.inc.php') /var/www/vhosts/1/127061/webspace/httpdocs/admin8254/index.php:33 0.1413 2506680 3. define() /var/www/vhosts/1/127061/webspace/httpdocs/config/config.inc.php:105 I can't see any references to module names. I have installed about 10 modules, all purchased from the PrestaShop store. I should mention that this site has been transferred from another server, but the same error occurs there too. Guess I'll start deleting the installed modules one by one, and see if I can find the problem that way. Link to comment Share on other sites More sharing options...
NemoPS Posted June 13, 2014 Share Posted June 13, 2014 You can simply try disabling them first, then remove them. If it doesn't help, at this point use the following, silimar to what you did before if(!defined(__PS_BASE_URI__)) define('__PS_BASE_URI__', $context->shop->getBaseURI()); Link to comment Share on other sites More sharing options...
Recommended Posts