Send email
- This topic has 4 replies, 2 voices, and was last updated 6 years, 2 months ago by .
Viewing 4 reply threads
Viewing 4 reply threads
- You must be logged in to reply to this topic.
Home › Forums › Classic DFFS › Send email
Tagged: Email button
It would appear that using <input type=”button” onclick=”spjs.dffs.processEmailTemplate(‘TemplateID’)” value=”Send E-Mail”> sends the email but redirects to the list view. How can I stop this?
Thanks!
Try it like this:
<input type=”button” onclick=”spjs.dffs.processEmailTemplate(‘TemplateID’);return false;” value=”Send E-Mail”>
Alexander
Yeah that was my go to lol but didn’t work.
Which browser are you using? and is it New, Disp or EditForm?
Alexander
I had a look at the code now and this is actually a bug. When you call spjs.dffs.processEmailTemplate it will trigger a save after the email is sent.
It was not supposed to do that when you manually triggered an email, but I usually do that in DispForm so I haven’t noticed the form being saved (this will of course not happen when in DispForm).
I’ll address this issue in the next release.
PS: If you want to send the email when the form is saved – and not immediately when they click the button – you can call this function instead:
spjs.dffs.handleEmailTemplate("TemplateID", true);
Alexander