1
panigrc
[emergency] mysql 4.1 and greek encoding
  • 2005/12/3 13:28

  • panigrc

  • Not too shy to talk

  • Posts: 133

  • Since: 2005/4/14


Ok here we are ... I changed to a server with MySQL 4.1 from older mysql.

I migrated successfully the database. The site is working 100% with greek characters!!

But when I go to phpMyAdmin the encoding of tables text and varchars is latin_swedish (default) and not right shown.

I don't understand because,

I migrated to another database my old database with all the structure to utf_unicode_ci the data in phpMyAdmin is all right shown

BUT IN MY SITE I see ONLY ????? (questionmarks)

Please help !!! Its an emergency
[size=xx-small]X-Park Greek Pc Modding Community
Official Greek Support at XoopsGreece.gr[/size]

2
LazyBadger
Re: [emergency] mysql 4.1 and greek encoding

You can read this old my thread and'll learn - nothing was done.
Quis custodiet ipsos custodes?

Webmaster of
XOOPS2.RU
XOOPS Modules Proving Ground
XOOPS Themes Exhibition

3
panigrc
Re: [emergency] mysql 4.1 and greek encoding
  • 2005/12/3 13:55

  • panigrc

  • Not too shy to talk

  • Posts: 133

  • Since: 2005/4/14


Yes but I don't understand where to put these

Quote:

mysql_query('SET character_set_results="cp1251"');
mysql_query("SET CHARACTER SET cp1251");
mysql_query("SET NAMES 'cp1251'");


And has this code worked ??
[size=xx-small]X-Park Greek Pc Modding Community
Official Greek Support at XoopsGreece.gr[/size]

4
LazyBadger
Re: [emergency] mysql 4.1 and greek encoding

class/database/mysql.php, function connect() before

return true;

and charset must be changed to your local charset (-1258?)

PS - it will not work on admin-side, you have to swich into english in admin backend
Quis custodiet ipsos custodes?

Webmaster of
XOOPS2.RU
XOOPS Modules Proving Ground
XOOPS Themes Exhibition

5
panigrc
Re: [emergency] mysql 4.1 and greek encoding
  • 2005/12/3 14:43

  • panigrc

  • Not too shy to talk

  • Posts: 133

  • Since: 2005/4/14


Thanx !!! Where can i find my local charset

In the database the characters wich display right have charset utf-8_unicode_ci
[size=xx-small]X-Park Greek Pc Modding Community
Official Greek Support at XoopsGreece.gr[/size]

6
LazyBadger
Re: [emergency] mysql 4.1 and greek encoding

"View Page Info" of your live site
Quis custodiet ipsos custodes?

Webmaster of
XOOPS2.RU
XOOPS Modules Proving Ground
XOOPS Themes Exhibition

7
panigrc
Re: [emergency] mysql 4.1 and greek encoding
  • 2005/12/3 15:46

  • panigrc

  • Not too shy to talk

  • Posts: 133

  • Since: 2005/4/14


I post the solution

i put the code as you said before return true;
in /class/database/mysqldatabase.php

mysql_query('SET character_set_results="utf8"');
mysql_query("SET CHARACTER SET utf8");
mysql_query("SET NAMES 'utf8'");


The database has to be with encoding utf8_unicode_ci

All the tables (text and varchar fields) with utf8_unicode_ci

phpMyAdmin shows right the data

And XOOPS too !!!
[size=xx-small]X-Park Greek Pc Modding Community
Official Greek Support at XoopsGreece.gr[/size]

8
panigrc
Re: [emergency] mysql 4.1 and greek encoding
  • 2005/12/3 15:47

  • panigrc

  • Not too shy to talk

  • Posts: 133

  • Since: 2005/4/14


I want to thank you and all the people helped me for this

(special thanx to MySQL developer docs !)
[size=xx-small]X-Park Greek Pc Modding Community
Official Greek Support at XoopsGreece.gr[/size]

9
panigrc
Re: [emergency] mysql 4.1 and greek encoding
  • 2005/12/4 11:18

  • panigrc

  • Not too shy to talk

  • Posts: 133

  • Since: 2005/4/14


The problem isn't solved !!!

[EMERGENCY]

After deleted the template_c folder the blocks didn't sho up no blocks system/module/and custom !!!

I installed local webserver with php 4.4 andi MySQL 4.1 and made to version one with

latin_swedish_ci

and one wiht

utf8_unicode_ci

and made fresh install to both of them

in the latin version the blocks show up right !!
in the utf8 the blocks show up but no contents are there !!

I assume something happens with getting contents from the database.

I hacked mysqldatabase.php and the problem remains please HELP !!!
[size=xx-small]X-Park Greek Pc Modding Community
Official Greek Support at XoopsGreece.gr[/size]

10
panigrc
Re: [emergency] mysql 4.1 and greek encoding
  • 2005/12/4 11:27

  • panigrc

  • Not too shy to talk

  • Posts: 133

  • Since: 2005/4/14


What can I do to XOOPS to make it understand that the contents are in utf8 and not in latin ?
Or what makes XOOPS not to fetch the contents of the blocks ?
[size=xx-small]X-Park Greek Pc Modding Community
Official Greek Support at XoopsGreece.gr[/size]

Login

Who's Online

166 user(s) are online (118 user(s) are browsing Support Forums)


Members: 0


Guests: 166


more...

Donat-O-Meter

Stats
Goal: $100.00
Due Date: Apr 30
Gross Amount: $0.00
Net Balance: $0.00
Left to go: $100.00
Make donations with PayPal!

Latest GitHub Commits