Jump to content

passing an array of products to email template ps 1.7 and 1.6


Recommended Posts

in my send function (mail)


 $products= $this->context->cart->getProducts();


   '{products}' =>$products


 return Mail::send(



        $subject="some thing",

        $templateVars= $vars  ,







        _PS_MODULE_DIR_ . $this->name . '/mails/'



in my mails directory =>en

i have example.html and example.txt

how can i loop throw the products? in thows files

i tried to add example.tpl but that not working


Edited by avi_t (see edit history)

Share this post

Link to post
Share on other sites

  • 1 year later...

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...

Important Information

Cookies ensure the smooth running of our services. Using these, you accept the use of cookies. Learn More