Ticket #71 (closed defect: fixed)

Opened 2 years ago

Last modified 20 months ago

Wrong codes in translation field when copying from original or using google translator

Reported by: irdb Owned by: somebody
Priority: normal Milestone: 1.0
Component: interface Version:
Keywords: Cc:

Description

Wrong codes in translation field when using "Copy from original" or "Translation from Google" links. Here is a picture:
http://fractol.files.wordpress.com/2010/02/capture.png

As you can see, the new line character (↵) is copied like this:

<span class="invisibles" title="New line">↵</span>

If we add this translation, a warning is generated:
Warning: Too many tags in translation.

Same thing goes for greater than and less than signs:

>
&gt

<
&lt

and a few other symbols, like:

&
&amp;

Attachments

glotpress.png Download (4.8 KB) - added by c00l2sv 22 months ago.
html entities should not be escaped

Change History

comment:1   irdb2 years ago

  • Priority changed from normal to major

html entities should not be escaped

  • Status changed from new to closed
  • Resolution set to fixed

(In [474]) Switch to .html() for setting textareas contents. .val() was expecting to see the text and double-escaped the result of other jQuery.prototype.html. Fixes #71

  • Status changed from closed to reopened
  • Resolution fixed deleted

I still have problem, so I reopen the topic.
http://dalba.files.wordpress.com/2010/04/capture.png

The change still wasn't deployed on translate.wordpress.(com|org). Could you confirm that it works now?

Could you hard refresh if any Javascript is still loaded from cache. It works for me on both Firefox and Safari.

  • Status changed from reopened to closed
  • Resolution set to fixed

I had to clear the cache. Now works fine. Thanks!

  • Status changed from closed to reopened
  • Resolution fixed deleted

I can't reproduce those. What browser and version are you using?

I'm using Firefox 3.6.3 (tested on both Ubuntu and windows 7)

Also noticed that in Chrome, the code is copied correctly, but not in Firefox.
I don't have access to IE(8) right now, but I think it was the same as Firefox.

  • Priority changed from major to normal
  • Component changed from general to interface
  • Milestone set to 1.0
  • Status changed from reopened to closed
  • Resolution set to fixed

[510] removes all these spans on copy and fixes the bug.

Note: See TracTickets for help on using tickets.