cypht-org / cypht

Cypht: Lightweight Open Source webmail aggregator [PHP, JS]
http://cypht.org
GNU Lesser General Public License v2.1
949 stars 146 forks source link

Handle Unicode in folder names #1012

Closed kambereBr closed 1 month ago

kambereBr commented 1 month ago

Pullrequest

This PR ensures compatibility with multibyte characters, including Cryllic characters in folder names

Issues

https://github.com/cypht-org/cypht/issues/756

How2Test

msedge_w99l4OwJny

kroky commented 1 month ago

It is OK to merge this as we already require mbstring extension in composer and sparingly use it mainly to convert encodings. However, if we want proper unicode support, we should do much more with the code. I see 170 different usages of substr only and there are a bunch of other string related functions that need to be converted to their multibyte counterparts - e.g. strtolower, strtoupper, strlen, strstr and probably others. @marclaporte maybe we merge this one now to fix the reported issue and release 2.0.1 and then open a PR for the rest of the places that need fixing for version 2.1.0?