I did a little search in the CB code and found a problem with a regexp in the validate function in components/com_comprofiler/plugin/user/plug_cbcore/cb.core.php.
I think there is something wrong with this regexp:
[code:1]if ($version == 1) {
// "^[a-zA-Z](([\.\-a-zA-Z0-9@])?[a-zA-Z0-9]*)*$", "i"«»);
$regex="/^[\<|\>|\"|\'|\%|\;|\(|\)|\&|\+|\-]*$/i";[/code:1]
It will only match if the username only has these characters or it’s an empty string because of the beginning and end of string delimiters (^ and $). Please correct me if I’m wrong, I’ve done regexps before but I’m not an expert in the matter and they tend to be tricky.
I’ve changed the regexp to something more straightforward as [code:1]/[^\w+]/[/code:1]. This way it only match when non-alphanumeric characters are present.
I suppose that the profile does not exist problem with Joomla SEF enabled was not taken into account since usernames are not supposed to have non-alphanumeric characters.
Please correct me if I'm wrong.
Arunas
Post edited by: amazeika, at: 2008/08/21 13:46
Post edited by: amazeika, at: 2008/08/21 13:47
Post edited by: amazeika, at: 2008/08/21 13:49
Post edited by: amazeika, at: 2008/08/21 13:54