Line breaks not recognized when translating text from a textarea
GoogleCodeExporter opened this issue · 1 comments
GoogleCodeExporter commented
jquery-translate version: 1.4.7
jQuery version: 1.5.2
browser: firefox 4.0.1
OS: Win 7
What is the expected output? What do you see instead?
I expect that the line breaks are submitted to the translated text when the
translation is finished. But it is just one whole block of text. No single line
break.
How to solve this problem?
It is a great plugin, I am using it now for 2 months and I am still exited!
Original issue reported on code.google.com by kees...@cannect.nl
on 25 May 2011 at 9:29
GoogleCodeExporter commented
To solve my own issue:
var nl = /\n|\r|\r\n/
textToTranslate = textToTranslate.replace(nl, '<br />');
Thanks!
Original comment by kees...@cannect.nl
on 25 May 2011 at 9:49