Hello, I'd need to set charset for my mediawiki 1.15.3 to latin1 instead of utf8 default
this because I cannot convert my mysql DB to utf8. All tables in mysql DB are set to latin1. if I convert it to utf8 I have key lenghtness errors.
Actually special characters are mangled in my mediawiki pages since I upgraded from an old mediawiki version 1.5.* to version 1.15.3
how can I Solve this ? is there a way to set latin1 charset in mediawiki 1.15.3 ?
thanks
Rick
Riccardo Veraldi wrote:
Hello, I'd need to set charset for my mediawiki 1.15.3 to latin1 instead of utf8 default
this because I cannot convert my mysql DB to utf8. All tables in mysql DB are set to latin1. if I convert it to utf8 I have key lenghtness errors.
Actually special characters are mangled in my mediawiki pages since I upgraded from an old mediawiki version 1.5.* to version 1.15.3
how can I Solve this ? is there a way to set latin1 charset in mediawiki 1.15.3 ?
thanks
Rick
You can't. MediaWiki will always work with utf-8. However, note that MediaWiki can also work with utf-8 text stored in text fields that msysql thinks are latin1 ($wgDBmysql5 = false).
If the key lenghts are not appropiate, change them. http://www.mediawiki.org/wiki/Manual:Errors_and_Symptoms#Specified_key_was_t...
ater trying to move from latin1 to utf8 and conerting enconding using sed I ahev this error:
mysql -u root -p < wikidb.190510-4.utf8.mysql Enter password: ERROR 1062 (23000) at line 237: Duplicate entry '0-Procom_Netforce_3000' for key 2
the latin1 file instead works... looks like something gets mangled
Platonides wrote:
Riccardo Veraldi wrote:
Hello, I'd need to set charset for my mediawiki 1.15.3 to latin1 instead of utf8 default
this because I cannot convert my mysql DB to utf8. All tables in mysql DB are set to latin1. if I convert it to utf8 I have key lenghtness errors.
Actually special characters are mangled in my mediawiki pages since I upgraded from an old mediawiki version 1.5.* to version 1.15.3
how can I Solve this ? is there a way to set latin1 charset in mediawiki 1.15.3 ?
thanks
Rick
You can't. MediaWiki will always work with utf-8. However, note that MediaWiki can also work with utf-8 text stored in text fields that msysql thinks are latin1 ($wgDBmysql5 = false).
If the key lenghts are not appropiate, change them. http://www.mediawiki.org/wiki/Manual:Errors_and_Symptoms#Specified_key_was_t...
MediaWiki-l mailing list MediaWiki-l@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-l
Riccardo Veraldi wrote:
ater trying to move from latin1 to utf8 and conerting enconding using sed I ahev this error:
mysql -u root -p < wikidb.190510-4.utf8.mysql Enter password: ERROR 1062 (23000) at line 237: Duplicate entry '0-Procom_Netforce_3000' for key 2
I guess you used sed to change the KEY length? Which exact command did you use?
the latin1 file instead works... looks like something gets mangled
You can use the wiki with mysql thinking it's latin1.
you guessed correctly!
I used this command.
sed -e 's/character set latin1 collate latin1_bin/character set utf8 collate utf8_unicode_ci/gi' -e 's/CHARSET=latin1/CHARSET=utf8/g' wikidb.190510.latin1.mysql > wikidb.190510.utf8.mysql
any hints on any error I could have made ?
thanks
Rick
Platonides wrote:
Riccardo Veraldi wrote:
ater trying to move from latin1 to utf8 and conerting enconding using sed I ahev this error:
mysql -u root -p < wikidb.190510-4.utf8.mysql Enter password: ERROR 1062 (23000) at line 237: Duplicate entry '0-Procom_Netforce_3000' for key 2
I guess you used sed to change the KEY length? Which exact command did you use?
the latin1 file instead works... looks like something gets mangled
You can use the wiki with mysql thinking it's latin1.
MediaWiki-l mailing list MediaWiki-l@lists.wikimedia.org https://lists.wikimedia.org/mailman/listinfo/mediawiki-l
mediawiki-l@lists.wikimedia.org