[TYPO3-dev] Install tool removes dots from admin usernames

Steffen Kamper info at sk-typo3.de
Sat Jan 10 16:16:58 CET 2009


Hi,

Stefano Kowalke schrieb:
> 
> Maybe do two patches? One for the dot issue and one for change ereg_replace
> to preg_replace.
>
no, it's ok in one


> It seems it not easy changing. If i replace ereg_replace preg_replace i got
> an error:
> Warning: preg_replace() [function.preg-replace]: Compilation failed: POSIX
> named classes are supported only within a class at offset 1 on
> 

the syntax is bit different, also the - in characterclass has to be escaped

  preg_replace('/[^A-Za-z0-9_\-.]/','',$username)

would do the job

vg Steffen




More information about the TYPO3-dev mailing list