Replies: 2 comments 4 replies
-
|
This is how the Android strings behave in the translate-toolkit (the library Weblate uses for parsing translation files) - once the string is a valid XML, it is inserted as XML. |
Beta Was this translation helpful? Give feedback.
-
|
Hello! I would like to ask the same question again to check whether a solution is available now. The situation is still the same. We have strings in the XML file that contain HTML entities. These are displayed as the characters they represent in the translation web interface (probably done by the browser), and when the string is saved, it contains the special characters instead of the HTML entities. As a result, less-than and greater-than characters end up in the XML file, which makes it invalid and causes issues in our Android and iOS apps. Example: Our source strings look like this: In the weblate interface this string is displayed as And finally the string is saved back to the XML file as Is there any way to prevent this from happening or to fix it before the file is committed? |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Hi!
We have source strings like this:
<string name="example">This is <b>bold</b> text.</string>Whenever a string like this is translated, it gets converted to
<string name="example">This is <b>bold</b> text.</string>We have tried to activate safe-html as flag and enforced check but still the same is happening. Is there any way to make Weblate save those HTML entities again and not convert them into characters? If our approach is bad, we are happy for any suggestions.
René
Beta Was this translation helpful? Give feedback.
All reactions