Text is truncated after ampersand (&) in Japanese .txt files

Hi,

I found a rendering bug in ONLYOFFICE when opening or previewing .txt files.

When a text file contains a half-width ampersand (&), all the text following the & symbol disappears and is not displayed at all.

I am writing my text in Japanese, and it completely cuts off right at the ampersand. It seems like the preview engine mistakenly treats the ampersand as HTML/XML code rather than plain text, causing a parsing error.

Could you please check and fix this issue?

Hi,

Thank you for your report and for the detailed description.

We tried to reproduce the issue with Japanese .txt files containing a half-width ampersand character, but on our side, all text after the ampersand is displayed correctly.

Could you please let us know which ONLYOFFICE product and version you are using?

If you are using an older version, please update to the latest available release and check the behavior again.

If the problem still persists after the update, please attach the original .txt file in which this occurs, along with a short screen recording showing how you open it and where the text gets cut off, so we can investigate the issue further.

Hi,

Thank you so much for checking and for your quick response!

I updated my ONLYOFFICE to the latest version, Community Edition 9.4.0.129 (x64 msi), and tested it again. I am happy to report that the issue has been completely fixed in this version! All the text following the ampersand (&) is now displayed correctly.

I apologize for reporting this using an older version environment without checking the latest update first.

Thank you again for your time and great support!

Thank you for the update, and no worries at all.

We’re glad to hear that after updating to ONLYOFFICE Community Edition 9.4.0.129 the issue is no longer reproducible and the text after the ampersand is displayed correctly.

Thank you for confirming the result.