Welcome to the LimeSurvey Community Forum

Ask the community, share ideas, and connect with other LimeSurvey users!

Custom HTML for invite and remind mails

More
4 years 3 months ago #216721 by tomlydra
Hello,
I try to use custom HTML in my invite and remind emails like this (this is formalism given by my SMTP provider : Tipimail) :
Code:
<html><!--|{"X-TM-BULK":1,"X-TM-TAGS":["best","ag2021"]}|-->...

But received HTML contains that:
Code:
<html>
<!--|<span class=3D'em-expression em-haveerror' ><span class=3D"em-var-st=
ring">"X-TM-BULK"</span><span class=3D'em-error' title=3D' ' ><span title=
=3D"Syntaxe non pris en charge"> : </span></span>1, <span class=3D"em-var-s=
tring">"X-TM-TAGS"</span><span class=3D'em-error' title=3D' ' ><span title=
=3D"Syntaxe non pris en charge"> : </span></span><span class=3D'em-error' t=
itle=3D' ' ><span title=3D"Syntaxe non pris en charge"> [ </span></span><sp=
an class=3D"em-var-string">"best"</span>, <span class=3D"em-var-string">"a=
g2021"</span><span class=3D'em-error' title=3D' ' ><span title=3D"Syntaxe n=
on pris en charge"> ] </span></span></span>|-->

I read in other topics that [ or ] could be problematic, and could be { and } in my case. But I don't know how to escape this caracters and let it pass as it is.

If you have an idea! Many thanks!
The topic has been locked.
More
4 years 3 months ago #216724 by tpartner
To avoid ExpressionScript parsing the braces (and generating an error), always leave a space after opening curly braces and before closing curly braces.

Code:
<html><!--|{ "X-TM-BULK":1,"X-TM-TAGS":["best","ag2021"] }|-->...

Cheers,
Tony Partner

Solutions, code and workarounds presented in these forums are given without any warranty, implied or otherwise.
The following user(s) said Thank You: DenisChenu, tomlydra
The topic has been locked.
More
4 years 3 months ago #216736 by tomlydra
Thanks for the quick reply, and sorry to double-post in french.
The topic has been locked.
More
4 years 3 months ago #216772 by DenisChenu
;) C'est pardonné ;)
(c'est pas grave , mais c'est chiant quand tu voit que la réponse est déjà donné sur un poste en anglais …)

Assistance on LimeSurvey forum and LimeSurvey core development are on my free time.
I'm not a LimeSurvey GmbH member. - Professional support - Plugins, theme and development .
I don't answer to private message.
The topic has been locked.
Moderators: tpartnerholch

Lime-years ahead

Online-surveys for every purse and purpose