Ok, something is really really wrong...
i just downloaded a php script that changes the collation of all tables in a database to what the user specifies. I managed to change the collation of all tables to: "utf8_general_ci" but i still get the flippin question marks when I import pages in persian and arabic!!!!
This is not making any sense.....
any help is appreciated!
opps, i forgot to mention:
I have: PHP Version 4.4.9 and Mysql 5.0
-
MODX Staff
- 10,725 Posts
I believe Persian and Arabic require utf8_unicode_ci, if I’m not mistaken.
I tried that as well, and I still get question marks!
ok, well, i resolved the problem.
I created the database myself and manually set the collation to utf8_general_ci. then asked modx to use the existing database, with that collation that i manually set, and that worked!
So, the problem really is with the installer: If you allow it to create the database, even though you specificy utf8_general_ci, it will set the collation to something completely different.
btw opengeek, utf8_general_ci is fine for arabic/persian.
Thanks,
-
MODX Staff
- 12,272 Posts
Possibly your database users does not have permissions to change collations, but can create databases?
Ryan Thrash, MODX Co-Founder
Follow me on Twitter at @rthrash or catch my occasional unofficial thoughts at thrash.me
So, to put this issue to rest, the culprit was: Mysql!
When I login to my admin control panel and create a database, it defaults to latin1_german2_ci. The problem is not with modx obviously.
I am not really sure why 1and1 decided to have the mysql installation default to latin1_german2_ci? Anyways, the issue is easily resolved by simply changing the collation to the desired one (general utf8) then linking modx to the database.