Send email with HTML body
Hi, I have face the following issue. We have a web service, which posts to another system to generate passwords. Then this password is sent by email to customer in HTML body using your post-function. Now about the problem.
<body> Hi, %{Reporter's full name}! <br /> <br /> %{Custom email body} <br />
<br /><br /> <hr />
<div id="custom_id" class="panel panel-default"> <div class="panel-body custom_class" style="background-color:#C1D2D2"> <h4 class = "panel-body">This letter is for informational purposes only. Please do not reply. </h4> </div> </div>
</body>
When %{Custom email body} contains '<', for example, S<nd77 the message is trunced after this symbol. Could you please advice some workaround? Thanks in advance!
Comments (6)
-
repo owner -
reporter Hi Fidel, The field is setting in groovy script on transition. It takes value from the response of the web service. But, not I've tried to do the same with field on the screen of transition.
-
reporter Problem is here for tex field on the screen, too.
-
repo owner @SaidAslan,
Try using "Copy a parsed text to a field" post-function just before "Send an email" post-function with the following configuration:
- Target field: Custom email body
- Parsing mode: advanced
- Text to be parsed...:
escapeHTML(%{nnnnn})
replacing nnnnn with field code for Custom email body custom field.
-
reporter It helped! Thank you!
-
repo owner - changed status to resolved
You are welcome :)
- Log in to comment
Hi @SaidAslan,
Can you, please, show me the post-function you are using for setting field Custom email body? A screenshot with the configuration of the post-function will be ok.