Page 1 of 1

Error accessing customers information

Posted: Sun Jun 12, 2016 10:58 pm
by txyaaj
Ok I am starting to sound like a broken record, but I need help, again!

Fresh install of OC2.2.0 in subdirectory /shop:
While trying to access the customers >> customers, I got this error msg. It appears to be missing a ")", but I think all the closing parantheses seem to have matching pairs.

Any help would be greatly appreciated.
Parse error: syntax error, unexpected '&&' (T_BOOLEAN_AND), expecting ')' in /home1/modernf2/public_html/shop/admin/controller/customer/customer.php on line 1105
Line 1005:

Code: Select all

					} elseif (($custom_field['type'] == 'text' && !empty($custom_field['validation'] && $custom_field['location'] == 'address')) && !filter_var($value['custom_field'][$custom_field['custom_field_id']], FILTER_VALIDATE_REGEXP, array('options' => array('regexp' => $custom_field['validation'])))) {

Re: Error accessing customers information

Posted: Sun Jun 12, 2016 11:40 pm
by artcore
empty() is a function so should be like
empty($custom_field['validation']) <-- this ')' is missing
and possibly loose a ')' somewhere else.

If you open this in an IDE (Aptana, PHPStorm,...) it will immediately tell you what's wrong so maybe the OC devs don't use that ;D

Re: Error accessing customers information

Posted: Sun Jun 12, 2016 11:59 pm
by AlexDW

Re: Error accessing customers information

Posted: Mon Jun 13, 2016 4:35 am
by txyaaj
Thanks! Got it fixed.