LDAP: transliterate other latin characters to ASCII when creating owncloud names. Already created usernames are not being affected.

This commit is contained in:
Arthur Schiwon 2012-08-27 21:32:32 +02:00
parent 84a5faff36
commit 5985d00c6f
1 changed files with 4 additions and 0 deletions

View File

@ -564,6 +564,10 @@ abstract class Access {
return $name;
}
// Translitaration
//latin characters to ASCII
$name = iconv('UTF-8', 'ASCII//TRANSLIT', $name);
//REPLACEMENTS
$name = \OCP\Util::mb_str_replace(' ', '_', $name, 'UTF-8');