Translating the subject line of e-mails sent by FoxyCart to my customers

AntonSyAntonSy Member
Hi,

The documentation at https://wiki.foxycart.com/v/2.0/i18n#customising_the_email_subject describes a technique for translating the subject line of the automatically-generated e-mails that FoxyCart sends to my customers.

But that technique only affects the *Receipt* e-mail, right? I presume that all e-mails (including dunning) use the same template (which I can customize in the Admin at TEMPLATES -> email receipt), but that any e-mail which isn't the Receipt e-mail gets its subject line from the template set (TEMPLATES -> language) and ignores the customized Receipt e-mail subject. (Certainly, the fields available at TEMPLATES -> language do include input boxes for subject lines of other e-mails, such as the dunning e-mail [TEMPLATES -> language -> email -> "subject subscription past due"].)

Please could you confirm!
Comments
  • fc_adamfc_adam FoxyCart Team
    @AntonSy,

    Good question. The current email template does apply to all emails we send out, affecting both email receipts and dunning emails.

    For the receipt email, the subject is taken from the email settings page, but for dunning emails, the subject comes from the language section (email_subject_subscription_cancelled, email_subject_subscription_past_due and email_subject_expiring_payment_reminder).

    If you customise the email subject using Twig, that customisation will overwrite whatever subject is set above. I believe the information we added in the section you linked to pre-dates our subscription dunning functionality, so didn't take that into consideration. I've just updated that section to account for that, both in the details, and in the example code.

    I hope that helps!
  • AntonSyAntonSy Member
    Thanks Adam; I see that in the new Twig snippet you've manually excluded the three subscription-related e-mails using an if-block (and so I infer that FoxyCart doesn't send out any other type of e-mail). We'll go ahead and use that new Twig code.
Sign In or Register to comment.