Cacahouet Posted March 3, 2017 Share Posted March 3, 2017 Hi Every, I Need help : I use a webservice for my products (simply to display the quantity)It's works with the product reference.So I created a function in FrontController.php in override like this: <?php class FrontController extends FrontControllerCore { public function initHeader(){ $clienttest = new SoapClient('webservice.awws?wsdl'); $reftest = $this->product->reference; $paramstest = array('codeart'=>$reftest); $responsetest = $clienttest->__soapCall('quantite', array($paramstest)); foreach($responsetest as $valeurtest) { } self::$smarty->assign('testtest', $valeurtest); return parent::initHeader(); } } It's good to display $valeurtest in product.tpl but not in product-list.tpl, it would actually be to retrieve the reference of the product of product-list.tpl to include it in my function. Someone would have any idea ?Thank you Link to comment Share on other sites More sharing options...
Cacahouet Posted March 3, 2017 Author Share Posted March 3, 2017 My Prestashop version : 1.6.1.9 Link to comment Share on other sites More sharing options...
Recommended Posts
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 accountSign in
Already have an account? Sign in here.
Sign In Now