do a couple simple conversions of htmlified characters to their ascii equivalent

This commit is contained in:
Brian S. Stephan 2010-07-26 18:33:10 -05:00
parent 8fba54e33d
commit 3bd8fb13c2
1 changed files with 6 additions and 0 deletions

View File

@ -180,6 +180,12 @@ class GoogleTranslate(Module):
translation = content[start_idx:]
end_idx = translation.find('"}, "')
translation = translation[:end_idx]
# do some text conversion
translation = translation.replace('\\u0026quot;', '"')
translation = translation.replace('\\u003c', '<')
translation = translation.replace('\\u003e', '>')
if replypath is None:
return translation
else: