How to show Chinese Characters in an English Forum

Started by stageducky, November 03, 2008, 10:36:52 AM

Previous topic - Next topic

Sarge

Quote from: antechinus on November 23, 2008, 04:06:16 AM
ETA: Read the other topic and basically that just says I have to convert my database to UTF-8 rather than just using the trick you use. I was hoping to avoid having to do the conversion.

No, you only need to do the conversion to UTF-8 if you need support for multiple languages, as agridoc mentioned:
Quote from: agridoc on November 22, 2008, 03:56:29 PM
It's a good solution for an old working forum or for ISO-8859-1 and another character set language, no need for database conversion. However, for true multilingual and many languages, UTF-8 is the proper solution.

If -- and only if -- your forum database tables are using the latin1 charset (and the latin1_swedish_ci collation by default) and your SMF installation is using UTF-8, there's still a problem here. You can fix this by deleting global_character_set as described in reply #10 in the other topic. (Be sure to select the forum database before going to the SQL box.) Whether you want to convert to UTF-8 afterwards or not... that's up to you. :) If you don't want to convert, then try agridoc's trick.

    Please do not PM me with support requests unless I invite you to.

http://www.zeriyt.com/   ~   http://www.galeriashqiptare.net/


Quote
<H> I had zero posts when I started posting

Antechinus

Just noting that I ran the query from the other thread and Agridocs's trick still doesn't work, so it looks like UTF-8 or nothing.

Yes, the installation is in UTF-8 and the database tables are in latin1_swedish_ci.

Sarge

Quote from: antechinus on November 23, 2008, 10:08:37 PM
Yes, the installation is in UTF-8 and the database tables are in latin1_swedish_ci.

How did you verify that the SMF installation is still in UTF-8?

The query removes global_character_set (which defaults to ISO-8859-1 if it's missing) from the smf_settings database table. But after that, you also need to switch the language from English_Utf8 to English in Admin > Server Settings > "Default Forum Language".

It's possible that you have two entries for English there, both named "English" (not "English" and "English_Utf8"). A quick way to know which to select could be to:

1. Select one of the English entries;
2. Look at the HTML source code of the page (View > Page Source in Firefox) and search for this:

option value="english"

3. See if that line is like this:

<option value="english" selected="selected">English</option>


If not, you need to select the "other" English.

    Please do not PM me with support requests unless I invite you to.

http://www.zeriyt.com/   ~   http://www.galeriashqiptare.net/


Quote
<H> I had zero posts when I started posting

Antechinus

#23
Oh bother. Looks like I fluffed it. Server settings in SMF admin are plain English (have been for ages) but I thought you meant the display down in phpMyAdmin, which showed UTF-8.

I'll check the source code anyway and see what it says.

ETA: Yep, it's English alright.

Sarge

Go to Admin > Forum Maintenance. In the General Maintenance section (at the top), what is the last link (the link after "Empty out unimportant logs.")? Is it "Convert the database and data to UTF-8" or is it "Convert HTML-entities to UTF-8 characters"?

    Please do not PM me with support requests unless I invite you to.

http://www.zeriyt.com/   ~   http://www.galeriashqiptare.net/


Quote
<H> I had zero posts when I started posting

Antechinus

It isn't either because after a little debacle a while ago I edited Admin.template.php to remove anything I didn't normally use and rearrange some of the others. :D

I can edit those links back in. Thing is at the moment I'm trying to train my co-admin to actually be a co-admin so I wanted the template fool proof. The link displayed used to be "Convert HTML-entities to UTF-8 characters". I imagine it still would be.

Sarge

Quote from: antechinus on November 24, 2008, 03:27:27 AM
[...] I edited Admin.template.php to remove anything I didn't normally use [...]

Well, you can simply check out the links in the default (Core) theme, if that's not what you're currently using. Adding ?theme=1 to the forum URL (yourforum.com/index.php) should switch -- from the theme you (as admin) are using -- to Core temporarily.

    Please do not PM me with support requests unless I invite you to.

http://www.zeriyt.com/   ~   http://www.galeriashqiptare.net/


Quote
<H> I had zero posts when I started posting

Antechinus

I edited the default theme admin template because all the custom themes call that template anyway.
Like I said, I can undo the edits if necessary. I'll sort it tonight and see what shows up. No big deal.

Antechinus

Ok, done. It is now showing "Convert the database and data to UTF-8",
This is not the link that it used to show so obviously something has changed.

helio l lopes

Quote from: agridoc on November 17, 2008, 08:09:46 PM
antechinus you can use UTF-8, otherwise you can "cheat" by changing the codepage in index.english.php to windows-1256 or ISO-8859-6.

In Multilingual in SMF 1.1RC2 without UTF for Greek and other languages? you can find more on this solution.


HI COMPUART,

My forum has the English by default but I would like that Czech users could be able to post and to see their characters as well.

I've tried the trick suggested by Agridoc but nothing works.

In phpAdmin I have the collation like this: latin1_general_ci.

Could you give a help on this, please?


Regards,

Helio

Advertisement: