Jump to content

Post parameters


Recommended Posts

Hi

Im using hookdisplayProductButtons()

 public function hookdisplayProductButtons()
 {
   $id_product = Tools::getValue('id_product');
$sampleObj =newprice::loadByIdProduct($id_product);
   $this->context->smarty->assign(array(
    'new_price' => $sampleObj->new_price,
  ));   
   return $this->display(__FILE__, 'views/front/new.tpl');
 }

to add two input fields

new.tpl
<p>from: <input type="text" name="new_from" id="fdate" /></p>
<p>    to: <input type="text" name="new_to" id="tdate" /></p>

 

but I cant get that parameters from $_POST or Tools::getValue() on hook ActionCartSave() after clicking on "Add to cart" button.

Please help.

Link to comment
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
×
×
  • Create New...