Hi guys, I’m a bit confused about how develop my own processing task after the form submission, right now I need send the form’s conten by email using sendgrid, then:
- I need register the event ‘onFormProcessed’ but in which descendant class of Plugin must I define this?..for instance in the documentation this event is added inside the EmailPlugin.
Can I add this event inside the Form class?..or must I create my own class??
//could be something like this?
'onFormProcessed' => ['livedrive_handler', 0]
-
I write the handler for the event…the livedrive_handler
-
How can I include this in my process chain?..my process would be something like
process:
- captcha:
recaptcha_secret: ENTER_YOUR_CAPTCHA_SECRET_KEY
- save:
fileprefix: feedback-
dateformat: Ymd-His-u
extension: txt
body: "{% include 'forms/data.txt.twig' %}"
- livedrive
- message: Thank you for your feedback!
how can I achieve something like this?
thanks!