Skip to Content
Meniu
Trebuie să fiți înregistrat pentru a interacționa cu comunitatea.
Această întrebare a fost marcată
3 Răspunsuri
4794 Vizualizări

Hi!

I am trying to use the email_from field as receiving address in an email template. These addresses are not in our partner database. Unfortunately most emails come in with special characters like "JohnDoe"<jd@mail.xy>. The characters "<> mess up the mail address created through email_from.

How can I get around this? Thanks for any help!

Imagine profil
Abandonează
Autor Cel mai bun răspuns

Thank you for your comments about using RegEx, but there is even a much simpler solution: just use the |safe option.

The field sniplet ${object.email_from|safe} works perfectly.

Imagine profil
Abandonează
Cel mai bun răspuns

Maybe you can use regexp to clean up the addresses: https://docs.python.org/2/library/re.html

Imagine profil
Abandonează

Exactly something where regex is made for. +1.

Related Posts Răspunsuri Vizualizări Activitate
2
ian. 24
4321
2
ian. 24
10000
1
mar. 21
9559
0
ian. 19
7134
1
mar. 15
6904