0

I am trying to add subject to custom email template but it is not working.

1
  • How are you trying to add subject in email templates? Can you please explain a bit more? Aug 23, 2021 at 13:48

1 Answer 1

1

You will want to have this snippet at the top of your custom email template:

<!--@subject My Custom Email Template Subject @-->

app/code/[Vendor]/[ModuleName]/view/[{frontend|adminhtml}]/email/custom_email_template.html:

<!--@subject My Custom Email Template Subject @-->

{{template config_path="design/email/header_template"}}

<table cellspacing="0" cellpadding="0" border="0" width="100%">
    <tr>
        <td>
            Example Content
        </td>
    </tr>
</table>

{{template config_path="design/email/footer_template"}}

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge you have read our privacy policy.

Not the answer you're looking for? Browse other questions tagged or ask your own question.