Spaces are removed from the translation when it is longer than 75 characters

Issue

  • Language Override translation values have removed space when they are longer then 75 characters
  • Steps to reproduce:
    • Control Panel > Language overrides, add a new key, name it e.g. testing-translation
    • Add any value longer then 75 chars to any language
      e.g. "test test test test test test test test test test test test test test test t"
    • Save it and check it again
  • Actual result: 
    • When the value is longer than 75 characters, some spaces are removed from the text (the above example is 76 chars)

Screenshot_2023-05-03_at_8.18.02.png

Environment

  • Liferay DXP 7.4 U4+

Resolution

  •  Whitelisting
    com.liferay.portal.language.override.model.PLOEntry
    in Control Panel -> System Settings -> Security Tools -> AntiSamy Sanitizer solves the issue.
  • Please make sure that after adding com.liferay.portal.language.override.model.PLOEntry to the white list of AntiSamy Sanitizer, you save the changes and in the affected keys you set the correct values.
    The above whitelisting would not change back the modified values which already have the spaces removed before this configuration change.

Screenshot_2023-04-11_at_10.11.19.png

Additional Information

Was this article helpful?
0 out of 0 found this helpful