Jump to content

Pass parameter from controller to model


Recommended Posts

Hello,

 

I would like to pass my parameters from controller to model, function hook. Does anybody can help me?

 

That is my controller:

 

<?php


require_once('../../../config/config.inc.php');
require_once('../../../init.php');
require_once('../giftonordermodule.php');


$giftonordermodule = new GiftonorderModule();


$gift_id = Tools::getValue('gift');
if ($gift_id){
    
    echo $gift_id;
}


?>
 
Thanks
Edited by ileriya (see edit history)
Link to comment
Share on other sites

as far as i know it's not possible. it's because you use separate controller for this (controller and module class are separate things).

 

where you've got this: gift

Tools::getValue('gift');

 

i suppose that this is... some kind of $_POST param? maybe $_GET ? ... or... what?

Link to comment
Share on other sites

×
×
  • Create New...