Jump to content
Sign in to follow this  
melmel

Conditional Email Based On The User Type

Recommended Posts

You can add three virtual fields to your page 1 and 2 will keep the email template as static value and based on the user selection will assign the associated value to the third one. And add this script to an HTML Block at the end of the list:

<script>
function f_email(){
if (document.getElementById('InsertRecordFIELDNAME').value == "TITLE"){
document.getElementById("cbParamVirtual3").value=document.getElementById("cbParamVirtual1").value;}
else {
document.getElementById("cbParamVirtual3").value=document.getElementById("cbParamVirtual2").value;
}
}
document.getElementById("caspioform").onsubmit=f_email;
</script>

You need to replace all IDs with appropriate ID.

Share this post


Link to post
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...
Sign in to follow this  

×
×
  • Create New...