sgn
sgn copied to clipboard
Can't display other language correctly
Expected Behavior
I am localizing the website to Chinese, most of the pages work fine like below.

For Bugs:
But some pages are garbled

This only happens when the URL ends with a .pl file
English all works fine, only Chinese on the page is garbled.
After some search, I think this is something about code in cgi-bin folder, I tried to add "use utf8;" in some files but not working. I don't know if I am correct, but I think all the .pl files are code from the old mod_perl project, and mod_perl doesn't support utf8 well.
Any ideas on how to solve this issue?
Environment
Steps to Reproduce
Hi, thanks for the amazing work to translate to Chinese!
We should have replaced all of these pages by now, but it didn't quite happen 100%. For the about page, I think there is an alternate mason page as well that you should probably link to. How many pages have you seen that are still around that are based on the old mod perl? They are usually simple pages that can be replaced easily with mason pages.
For the display in the cgi-bin files, the problem may occur because most of the content is read in from files. The filehandles need to be opened as utf-8 encoded filehandles, such as open(my $F, "< :encoding(UTF8)", $filename) ...
Hi Huiyn, if that suggestion didn't work let me know, otherwise I will close this ticket. Thanks again for letting us know.
cheers Lukas