nswdpc / silverstripe-structured-email
Structured email for Silverstripe
Installs: 314
Dependents: 0
Suggesters: 0
Security: 0
Stars: 0
Watchers: 1
Forks: 0
Open Issues: 0
Type:silverstripe-vendormodule
Requires
Requires (Dev)
- cambis/silverstan: ^1
- cambis/silverstripe-rector: ^1
- nswdpc/ci-files: dev-v-3
- phpunit/phpunit: ^9.5
Suggests
- ext-tidy: Use tidy to process HTML documents
- ext-xml: Use DOMDocument to process HTML documents
This package is auto-updated.
Last update: 2025-04-23 08:15:29 UTC
README
The goal of this module is to produce simple and easy-to-digest emails (more) using a consistent template. The templates used are based on the Postmark Transactional Email Templates.
For specific core emails, it will attempt to detect the purpose of the email based on the template name:
SilverStripe/Control/Email/ForgotPasswordEmail
- the forgot password emailSilverStripe/Control/Email/ChangePasswordEmail
- the changed password email
TODO:
SilverStripe/MFA/Email/*
- MFA emailsSilverStripe/ContentReview/*
- Content review emailsSubmittedFormEmail
- user defined form generic emailSubmittedFormEmailPlain
- user defined form generic email (plain text)
Existing templates
If the class encounters a complete HTML document in the email, it will use HTML contained within the <body>
tag of that document as the email content.
Schema.org
Resources
- E-mail support across clients: https://www.caniemail.com
- Postmark templates: https://github.com/ActiveCampaign/postmark-templates
Usage
- Create emails in the standard way
- The MailerSubscriber extension will catch emails prior to being sent
- Email content is updated based on the default template and decorator provided
- Emails will then be sent out with the updated template and a plain text part
Installation
The only supported way of installing this module is via composer
composer require nswdpc/silverstripe-structured-email
License
Maintainers
The source of the HTML email templates is the Postmark templates project
Bugtracker
We welcome bug reports, pull requests and feature requests on the Github Issue tracker for this project.
Please review the code of conduct prior to opening a new issue.
Security
If you have found a security issue with this module, please email digital[@]dpc.nsw.gov.au in the first instance, detailing your findings.
Development and contribution
If you would like to make contributions to the module please ensure you raise a pull request and discuss with the module maintainers.
Please review the code of conduct prior to completing a pull request.