Update rosetta.js

Yandex will convert < and > to html entities. Convert the entities back to normal characters.
This commit is contained in:
Marc Belmont 2014-10-27 10:18:55 +01:00
parent 19a2e7ed5a
commit 42c2492b85

View file

@ -63,7 +63,7 @@ google.setOnLoadCallback(function() {
dataType: 'jsonp',
success: function(response) {
if (response.code == 200) {
trans.val(response.text[0]);
trans.val(response.text[0].replace(/<br>/g, '\n').replace(/&lt;/g, '<').replace(/&gt;/g, '>'));
a.hide();
} else {
a.text(response);