websku Posted April 16, 2014 Share Posted April 16, 2014 Hello, I'm trying to print products from the order on the order-confirmation page. I've put this code and doesn't print anything. On Prestashop 1.4 it worked. <script> items = [ {foreach from=$products item=item name=vtitems}{literal}{id:’{/literal}{$item.id_product}{literal}’, quantity: {/literal}{$item.quantity}{literal[spam-filter] {/literal}{if !$smarty.foreach.vtitems.last},{/if}{/foreach} ]; </script> Thank you! Link to comment Share on other sites More sharing options...
NemoPS Posted April 16, 2014 Share Posted April 16, 2014 Uhm... you mean you want to add ordered products to a javascript array? It also depends on the payment method, not all of them assign $products as variable to that page Link to comment Share on other sites More sharing options...
websku Posted April 16, 2014 Author Share Posted April 16, 2014 Great to know that. Is there a way to make it work (same variable name) regardless payments modules? Link to comment Share on other sites More sharing options...
NemoPS Posted April 16, 2014 Share Posted April 16, 2014 Yes, create a new module that hooks there and assigns the variable Link to comment Share on other sites More sharing options...
vekia Posted April 16, 2014 Share Posted April 16, 2014 what payment method you use? do you tested it with various payment methods? Link to comment Share on other sites More sharing options...
Recommended Posts