i have installed opencart and i was trying to add a custom field in usr registration page,,but its showing error after regi,,any idea how to solve it?
Notice: Undefined index: address in /home/rapid/public_html/demo/catalog/controller/account/register.php on line 281
Fatal error: Unsupported operand types in /home/rapid/public_html/demo/catalog/controller/account/register.php on line 281
thanks
Find
$data['register_custom_field'] = $this->request->post['custom_field']['account'] + $this->request->post['custom_field']['address'];
Replace
if(isset($this->request->post['custom_field']['address'])){
$data['register_custom_field'] = $this->request->post['custom_field']['account'] + $this->request->post['custom_field']['address'];
} else {
$data['register_custom_field'] = $this->request->post['custom_field']['account'];
}
$data['register_custom_field'] = $this->request->post['custom_field']['account'] + $this->request->post['custom_field']['address'];
Replace
if(isset($this->request->post['custom_field']['address'])){
$data['register_custom_field'] = $this->request->post['custom_field']['account'] + $this->request->post['custom_field']['address'];
} else {
$data['register_custom_field'] = $this->request->post['custom_field']['account'];
}
Who is online
Users browsing this forum: No registered users and 191 guests