Jump to content

Conditional Acknowledgement E-Mail


Recommended Posts

I need some HTML help for an Acknowledgement E-Mail.  When I send an Acknowledgement E-mail to a customer, I want to send some additional information if they responded clicked on a checkbox in a submission form.  I believe this can be done with If and Else statements, but don't know how to write the script.  In layman's terms, this is what I'm looking for.

 

IF "Smart Meter Authorization" is checked,

THEN include a paragraph about Smart Meters

ELSE don't include a paragraph about Smart Meters

 

Thanks,

 

Scott

Link to comment
Share on other sites

Hello Scott,

 

If you use Submission DataPage, you can add virtual field on the 'Configure Fields' step, make it hidden, add the 'Header&Footer' field and paste the following code in the footer: 

<script type= "text/javascript">
function checkbox()
{
if(document.getElementById("InsertRecordSmart_Meter_Authorization").checked)
{
document.getElementById("cbParamVirtual1").value =  document.getElementById("InsertRecordSmart_Meters").value;
}
else document.getElementById("cbParamVirtual1").value = "";
}
document.getElementById("caspioform").onsubmit = checkbox;
</script>
Than go to the 'Email Options' step and insert virtual field using parameter picker in the HTML message body.
 
Hope it helps.
Link to comment
Share on other sites

  • 3 years later...

Hi @ScottECE,

Just an update: You can use send an Email using Triggered Actions. Triggered Actions allow data manipulation, calculations and sending notifications by constructing application logic with a visual interface. They will be executed on specified events to perform actions on data in your tables. For more information about Triggered Actions, check it here: https://howto.caspio.com/tables-and-views/triggered-actions/

Hope it helps!

Link to comment
Share on other sites

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.

Guest
Reply to this topic...

×   Pasted as rich text.   Paste as plain text instead

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

Loading...
 Share

×
×
  • Create New...