0

I upgraded prestashop from 1.4 to 1.6 with the automated update module. The backoffice works fine, but there is no front office being displayed. It gives me a server error 500. I turned debugging on and found the following lines at the end

define('_PS_CAT_IMG_DIR_',           _PS_IMG_DIR_.'c/');
define('_PS_COL_IMG_DIR_',             _PS_IMG_DIR_.'co/');
define('_PS_EMPLOYEE_IMG_DIR_',      _PS_IMG_DIR_.'e/');
define('_PS_GENDERS_DIR_',           _PS_IMG_DIR_.'genders/');
define('_PS_LANG_IMG_DIR_',          _PS_IMG_DIR_.'l/');
define('_PS_MANU_IMG_DIR_',          _PS_IMG_DIR_.'m/');
define('_PS_ORDER_S

The error that the debuging mode showed was :

Parse error: syntax error, unexpected ''_PS_ORDER_S' (T_ENCAPSED_AND_WHITESPACE) in C:\xampp\htdocs\prestashop\config\defines.inc.php on line 130

Line 130 is the last line of the snippet I posted. I am no programmer but it looks like it got trimmed or something. Do you have any ideas on what to put there?

Thanks

Morgoth
  • 47
  • 1
  • 2
  • 7

1 Answers1

0

You're right, it's cut off or "trimmed". After a lookup of the prestashop code, that whole line should be:

define('_PS_ORDER_STATE_IMG_DIR_',   _PS_IMG_DIR_.'os/');

However, if that's where that file ends, then you have a bigger problem and you'll need to reinstall those files.

defines.inc.php reference

Spartacus
  • 1,468
  • 2
  • 15
  • 29
  • When you say reinstall those files, you mean copy paste a healthy code or would I have to reinstall prestashop? – Morgoth Sep 15 '17 at 16:59
  • Copy/pasting the code might work, but how do you know other files weren't corrupted? Might be safer to reinstall the whole thing. – Spartacus Sep 15 '17 at 17:25
  • Unfortunately I can't reinstall prestashop because I already have hundreds of hours into it. I'll try and fix it. Thanks for your help! – Morgoth Sep 16 '17 at 07:12
  • This is bizarre! I found out that the reason for the php files getting jumbled up and "trimmed" is because I downloaded them through cpanel to my computer. Why on earth would that happen? They show up completely fine when I open them directly on cpanel! Maybe because I open them with notepad? I downloaded notepad++, hopefully this will fix it up. – Morgoth Sep 16 '17 at 08:45