Recent Topics

1 Sep 27, 2007 08:19    

My b2evolution Version: Not Entered

Hi, I am Gabriel Pradiipaka (a Sanskrit teacher and owner of "http://www.sanskrit-sanscrito.com.ar/answers/blogs/answering.html").

I have a blog (I am using the stable version of it -1.10.2-) and need very badly to know the way to generate contents in utf-8. The usual iso-8859-1 is really troublesome when you publish something in Sanskrit language (even transliterated is a unreadable stew of NCR's!). And creating/editing/posting with lots of Sanskrit is an insane task I have not "publicly" attempted yet, that is, I just made some tests in drafts and they looked terrible :( (you know, it is imposible to read so many NCR's).

Also, the Sanskrit text (even transliteration in Roman characters) is shown poorly in RSS readers due to the default character set iso-8859-1.

Any solution or simply I will have to wait for the next stable version?

Thanks

2 Sep 28, 2007 01:55

Not an area of expertise, but wouldn't changing the meta tag be a good place to start?

<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1" />

to

<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />

You'd simply need to change this in your skin's _main.php file.

Caveat: I've never played around much with character encoding, so maybe something more is required?

You might also check your regional setting in b2evolution (App Settings -> Regional) ... changing the charset there AND in the default "messages.pot" file in the "locales" subdir?

Hope this helps you.

3 Sep 28, 2007 05:29

I wish it was that simple. I've been looking into the topic this afternoon but I am not ready yet with a comlpete answer. A place to start is [url=http://forums.b2evolution.net/viewtopic.php?t=10992&start=0&postdays=0&postorder=asc&highlight=database+utf8]this post[/url], but the code mentioned works only for 1.9 versions of B2evo. If you can handle the changes in the database with phpMyAdmin, there is enough information in the article. Else I will have a thourough look at the presented code.

So please report back to this topic and keep checking it for more information.

Good luck

4 Sep 28, 2007 06:11

Afwas wrote:

I wish it was that simple. I've been looking into the topic this afternoon but I am not ready yet with a comlpete answer. A place to start is [url=http://forums.b2evolution.net/viewtopic.php?t=10992&start=0&postdays=0&postorder=asc&highlight=database+utf8]this post[/url], but the code mentioned works only for 1.9 versions of B2evo. If you can handle the changes in the database with phpMyAdmin, there is enough information in the article. Else I will have a thourough look at the presented code.

So please report back to this topic and keep checking it for more information.

Good luck

Yes, I thought in the same way as STK at first... but things looked too easy and I was afraid of ruining my database somehow. So, I stepped back and came here to consult the experts. Thanks STK, anyway.

Your post specifies v1.9 which is still alpha. I also read your other post with the fixes. A little complicated but I can handle it. The problem is that 1.9 is alpha yet. Maybe when it changes to beta, I will try that after backing up my database 1,987,998,776,998 times :lol: , you know. Drive safely... build a database safely, hehe.

No doubt I will keep checking this post for more information. It would be great a version including utf-8 by default. W3C recommends utf-8, although it is not obligatory. For people working with, say, eastern languages, it is a nightmare to edit NCR's (e.g. &#6547, etc.) represeting eastern characters. Yes, people can see "in the blog" the transliterated characters rather well (signs, at least, Sanskrit signs are shown terribly). Anyway, the problem comes if one has to edit some post with NCR's, haha. A real madness 8|

Thank you Afwas for your help. I am staying sharp for more tips!

5 Sep 28, 2007 07:14

I checked the code and found no errors, if you really did make a backup you can run the first code mentioned in the post I linked to. Remember to change three or four database essentials: Three in the first line:

$conn = mysql_connect("localhost", "YOURDBUSER", "YOURDBPASSWORD");

and one in line 42:

$rs2 = mysql_query("SHOW DATABASES LIKE 'YOURDBTOFIX'");

.
It spits out a tremendous list of SQL queries that you can copy/paste into a phpMyAdmin SQL box. Excecuting the commands will take a while, but a perfect adjusted database is the result.
Don't forget to change the conf/_locale.php file as metioned in the post.

Hope to hear from you. If you run into trouble or have subsequent questions also!

Good luck


Form is loading...