I am using Opencart 2.0.1.1
. There is hidden text field on product page that I want to post on cart page. I am following this tutorial but getting Undefined index
issue.
<input type="hidden" name="design" value="12">
I have done the following coding so for:
In catalog/controller/checkout/cart.php
$option['design']=$this->request->post['design'];
$this->cart->add($this->request->post['product_id'],$quantity,$option);
Then in $data['products'][] = array(
added 'design' => $product['design'],
Then in system/library/cart.php
In $this->data[$key] = array(
added 'design' => $options['design'],
Then in cart.tpl in view\theme\template-name\template\checkout\cart.tpl
echo $product['design'];
Can anyone please help me on this issue?