Created
September 20, 2017 18:59
-
-
Save alanfluff/95a49be190bc70ac25ee19442ecf92a2 to your computer and use it in GitHub Desktop.
Append Subject in outgoing emails - eg date time stamp
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<?php | |
// /site/ready.php | |
// Email subjects - add a datestamp to email subjects | |
$forms->addHookBefore('FormBuilderProcessor::emailForm', function($event) { | |
$processor = $event->object; | |
$formData = $event->arguments(1); // associative array of form data, if needed | |
$processor->emailSubject = $processor->emailSubject . " (" . date('Y/m/d H:i:s') . ")"; | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment