2.0.2 Username starting with ÅÄÖ doesn't work (General)

by Göran B @, Wednesday, February 25, 2009, 12:34 (5510 days ago)

Hi!
Upgraded successfully (almost) to 2.0.2 yesterday.

However, we have a problem.
Usernames starting with ÅÄÖ can't log in.
It works fine if the username contains åäö.

In the search function - searching on Å doesn't return anything.
å returns correctly all usernames with å in - A returns both A and Å.

Have we found a bug or are we doing anything wrong?

Additional info:
We have UTF-8 all the way - but of some reason are ÅÄÖ stored with other
characters if you login into MySQL. We had to comment out a row in function.inc.php about utf8 to get the correct results after the upgrade.

2.0.2 Username with ÅÄÖ doesn't work

by Göran B, Wednesday, February 25, 2009, 12:51 (5510 days ago) @ Göran B

Additional information:

All usernames containing Å, Ä eller Ö have problems.
All usernames containing å, ä eller ö are OK.

2.0.2 Username with ÅÄÖ doesn't work

by ÅÄÖ-Tester, Wednesday, February 25, 2009, 13:54 (5510 days ago) @ Göran B

Hi Göran,

sorry, no idea what's the problem, but there do not seem to be problems with these characters on this forum.

Alex

2.0.2 Username with ÅÄÖ doesn't work

by Göran B, Wednesday, February 25, 2009, 14:29 (5510 days ago) @ ÅÄÖ-Tester

Puhhh...
Then it is some mix-max for utf8 / latin1 for my database. My headache:-(
Thanks anyway!

2.0.2 Username with ÅÄÖ doesn't work

by Mattias, Wednesday, February 25, 2009, 15:29 (5510 days ago) @ Göran B

Regarding character set mismatches, there are some comments on this page that could be helpful:

http://dev.mysql.com/doc/refman/5.1/en/charset-unicode.html

Also, the entire chapter 9.1 is about character set support. One thing that might be the issue is that character set info can be set both in the server, the database, a table, or a table field, not to mention the connection.

2.0.2 Username with ÅÄÖ doesn't work

by Göran B, Wednesday, February 25, 2009, 17:18 (5510 days ago) @ Mattias

Regarding character set mismatches, there are some comments on this page that could be helpful:

http://dev.mysql.com/doc/refman/5.1/en/charset-unicode.html

Also, the entire chapter 9.1 is about character set support. One thing that might be the issue is that character set info can be set both in the server, the database, a table, or a table field, not to mention the connection.

I know... Been working with Oracle for the last 19 years :-)

I fixed my problem by a change in login.inc.php.
I replaced a part of a statement with the old code from Beta 25..

The best solution would be to convert my database into the right charset . but I don't have the knowledge and time...


   // $result = 
...
WHERE lower(user_name) = '".mysql_real_escape_string(my_strtolower($request_username, $lang['charset']))."'", $connid) or raise_error('database_error',mysql_error());
    // Replaced by:
    $result = 
...
WHERE lower(user_name) = '".mysql_real_escape_string(strtolower($request_username))."'", $connid) or raise_error('database_error',mysql_error());

2.0.2 Username with ÅÄÖ doesn't work

by Mattias, Wednesday, February 25, 2009, 17:40 (5510 days ago) @ Göran B

OK, then I suppose you don't need help with that :-)

I suspect you are aware of the error that remains on Postvagnen (assuming you are the same Göran)?

It still says


You have an error in your SQL syntax; check the manual that corresponds
to your MySQL server version for the right syntax to use near '-60, 60'
at line 1

.

In my own application I save errors like these to a file, along with a backtrace (using a custom function assigned by set_error_handler(), which also calls debug_backtrace()). I have no idea (haven't looked) how MLF does this but it would sure help to see the entire SQL query in question to figure out what's wrong with it.

One guess is that the "-60, 60" is part of a LIMIT clause which happened to receive a negative offset? That would be obviously illegal...

2.0.2 Username starting with ÅÄÖ doesn't work

by Ögli Ürünß ⌂, Thursday, April 16, 2009, 22:27 (5460 days ago) @ Göran B

au das wäre aber schlecht

RSS Feed of thread