Support Forum

Multibyte string for display name

DL DNB Labs
DNB Labs
Member

When trying to add a multibyte string as display name, the result is an empty string written to display_name in the member-table.

This might have something to do with the server setup, but that is not possible to change.

The function sp_filter_save_nocontrolchars() in sp-api-filters.php contains the non-multibyte function substr(). Can you please change it to mb_substr() (if it exists)?

$char = mb_substr($content, $x, 1, SFCHARSET);

Thanks!

3 Answers

New Answer

YS Yellow Swordfish
Yellow Swordfish
Member

As with the other I have opened a ticket for discussion.
Not sure about the need to check for the function to exist though. As far as I am aware it is now a part of the 5 core libraries… I think that happened with 4.0.6, Let me know if you know different please.

DL DNB Labs
DNB Labs
Member

I’m not sure, but the PHP manual says:

“mbstring is a non-default extension. This means it is not enabled by default. You must explicitly enable the module with the configure option.”, http://php.net/manual/en/mbstring.installation.php

It is also possible to disable the extension, so it’s maybe better to be safe than sorry? smile

YS Yellow Swordfish
Yellow Swordfish
Member

So it does… I thought that had changed with php 5