Sending custom Emails
  • I would like to be able to use a custom HTML email template to send email. I know I could use mail(), but the message gets incredibly convoluted with quotes and php loops, objects etc.

    Is there any way I could call something like what v:store:checkout does with the email_confirmation attribute?

  • 1 Answer sorted by
  • Yep, vae_template_mail().

    Here's how you use it:

    vae_template_mail($from, $to, $subject, $template, $text_yield = null, $html_yield = null);

    $template is an absolute path to the template, "/emails/template", for example. Make sure to make /emails/template.html and /emails/template.txt.html (plain text version).

    $text_yield is what will be put into the text template when you cann <v:yield />. Ditto for $html_yield, but with the HTML template.

    Hope that helps.

Howdy, Stranger!

It looks like you're new here. If you want to get involved, click one of these buttons!

Sign In Apply for Membership

In this Discussion