donato.gr
unread,Jun 21, 2010, 9:17:12 AM6/21/10Sign in to reply to author
Sign in to forward
You do not have permission to delete messages in this group
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to Django users
Hi,
I had this code in a template file:
alert('{% trans "a string" %}')
It gave error when translated bacause the translated string had a '
inside. So, I replaced " with ' in the template line and all worked
fine.
To avoid any problem with 'escape chars', is there a way to escape
translated strings, like the 'escapejs' filter tag does?
Something like "{% trans "a string" | escapejs %}"
Thank you