Im having a problem with customers editing their addresses they can't get in from the customer side.
they go to there "My Account" and can't access the address book page
is this a known people with a fix available ?
nothing comes up on the error long, i think its a bad bit of script, as it only comes up with a blank page.
go from the customer account page to the "address book" and nothing loads hence my thinking that its bad code.
go from the customer account page to the "address book" and nothing loads hence my thinking that its bad code.
Then you should check your server error logs (Apache error log) or (Nginx error log)
There is always a log of a real error behind a 500 error
There is always a log of a real error behind a 500 error
it says "mod_fcgid: stderr: PHP Parse error: syntax error, unexpected T_BOOLEAN_AND, expecting ')' in /var/www/vhosts/hiddenattire.co.uk/httpdocs/catalog/controller/account/address.php on line 522, referer: http://hiddenattire.co.uk/index.php?rou ... t/password"
im not massive on coding and can't see an error?
519 foreach ($custom_fields as $custom_field) {
520 if (($custom_field['location'] == 'address') && $custom_field['required'] && empty($this->request->post['custom_field'][$custom_field['custom_field_id']])) {
521 $this->error['custom_field'][$custom_field['custom_field_id']] = sprintf($this->language->get('error_custom_field'), $custom_field['name']);
522 } elseif (($custom_field['type'] == 'text' && !empty($custom_field['validation'] && $custom_field['location'] == 'address')) && !filter_var($this->request->post['custom_field'][$custom_field['custom_field_id']], FILTER_VALIDATE_REGEXP, array('options' => array('regexp' => $custom_field['validation'])))) {
523 $this->error['custom_field'][$custom_field['custom_field_id']] = sprintf($this->language->get('error_custom_field_validate'), $custom_field['name']);
}
}
im not massive on coding and can't see an error?
519 foreach ($custom_fields as $custom_field) {
520 if (($custom_field['location'] == 'address') && $custom_field['required'] && empty($this->request->post['custom_field'][$custom_field['custom_field_id']])) {
521 $this->error['custom_field'][$custom_field['custom_field_id']] = sprintf($this->language->get('error_custom_field'), $custom_field['name']);
522 } elseif (($custom_field['type'] == 'text' && !empty($custom_field['validation'] && $custom_field['location'] == 'address')) && !filter_var($this->request->post['custom_field'][$custom_field['custom_field_id']], FILTER_VALIDATE_REGEXP, array('options' => array('regexp' => $custom_field['validation'])))) {
523 $this->error['custom_field'][$custom_field['custom_field_id']] = sprintf($this->language->get('error_custom_field_validate'), $custom_field['name']);
}
}
Attachments
Screen Shot 2017-01-12 at 11.44.45.png (47.22 KiB) Viewed 1261 times
Please try replacing that line with the following:
Make a backup of the file before editing, just in case
Code: Select all
if (($custom_field['location'] == 'address') && ($custom_field['type'] == 'text') && !empty($custom_field['validation']) && !filter_var($this->request->post['custom_field'][$custom_field['custom_field_id']], FILTER_VALIDATE_REGEXP, array('options' => array('regexp' => $custom_field['validation'])))) {
Who is online
Users browsing this forum: No registered users and 127 guests