since quite a while I'm aware that PHP's string routines are not UTF-8 save. But now I've noticed that even trim() fails to strip UTF-8 non-breaking spaces. And I'm aware, that CMSimple_XH still uses several of the string routines in places which are prone to error. Consider e.g.
- Code: Select all
This results in garbage, if the first letter of $tx['action']['save'] is a non ASCII letter. PHP's mbstring extension offers several alternative functions, which are suitable for handling UTF-8. But unfortunately some of them are available only in newer PHP versions, and even worse several string functions are not implemented at all. I'm not sure, if mbstring is available on all servers, but I guess there's no other way than to rely on this extension to make CMSimple_XH UTF-8 save. Or should we wait for PHP6?