KonaKart Community Forum

Installation / Configuration => Configuration of KonaKart => Topic started by: costis on April 08, 2008, 08:19:19 pm

Title: utf-8 characters become ????????????
Post by: costis on April 08, 2008, 08:19:19 pm
Hello all!
How could we make the greek utf-8 characters, being entered by a customer, no to get converted to question marks ????????

We use mysql with UTF-8 and ci_general collation.

Please help!!!!!!! 
Title: Re: utf-8 characters become ????????????
Post by: pete on April 08, 2008, 08:49:49 pm
Hi,

Can you be a bit more specific about where this is happening ? Can you reproduce it on our online demo ?

Thx,

Pete
Title: Re: utf-8 characters become ????????????
Post by: costis on April 08, 2008, 09:04:49 pm
Thanks for your so quick response!!!
Here is the same situation on your demo. The question marks were once Greek letters before
saving to the database.....

If you could think of a solution there we would be very grateful!

Greetings
Costis (or better Κωστής)
Title: Re: utf-8 characters become ????????????
Post by: costis on April 08, 2008, 09:48:08 pm
You email arrived! Looks like this......
Is 7bit OK?
Title: Re: utf-8 characters become ????????????
Post by: pete on April 08, 2008, 10:09:33 pm
I've just tried it with a database set up for UTF-8 and it works. See attached image:
Title: Re: utf-8 characters become ????????????
Post by: costis on April 08, 2008, 10:15:02 pm
Wow! The fact is that it used to work for me too, but stopped suddenly and since then i keep getting
question marks. We use utf8 everywhere....
Did you use phpMyAdmin for your database settings?

Title: Re: utf-8 characters become ????????????
Post by: costis on April 08, 2008, 10:18:30 pm
The konakart demo, keeps giving me question marks though.....  ??? ???
Title: Re: utf-8 characters become ????????????
Post by: pete on April 08, 2008, 10:26:20 pm
Yes, the database for the online demo isn't setup correctly to store Greek characters.
Title: Re: utf-8 characters become ????????????
Post by: pete on April 08, 2008, 10:32:04 pm
My database seems to be setup in a similar fashion. If it used to work and suddenly stopped, you should try to figure out what you changed .
Title: Re: utf-8 characters become ????????????
Post by: costis on April 08, 2008, 11:01:34 pm
Thanx for all the support! One question more:

Do you have the URIEncoding="UTF-8" entry like here in your server.xml ?

<!-- Define a non-SSL HTTP/1.1 Connector on port 8080 -->
   <Connector port="8080" maxHttpHeaderSize="8192"
               maxThreads="150" minSpareThreads="25" maxSpareThreads="75"
               enableLookups="false" redirectPort="8443" acceptCount="100"
               connectionTimeout="20000" disableUploadTimeout="true"
               URIEncoding="UTF-8"
   />
Title: Re: utf-8 characters become ????????????
Post by: costis on April 08, 2008, 11:44:01 pm
 URIEncoding="UTF-8" does not do the trick either.....  :( :( :(
Title: Re: utf-8 characters become ????????????
Post by: costis on April 09, 2008, 12:00:44 am
but then again on my system Verrueckt nach Mary comes with a Question Mark,
while on konakart-demo site it is OK.........

Help needed!
Title: Re: utf-8 characters become ????????????
Post by: pete on April 09, 2008, 06:29:11 am
My system works after a standard KonaKart install using our installer. From what you said, it looks like your system used to work when you first installed it. My advice is to go through a fresh install process and try again. Are you running on Windows or Linux ?
Title: Re: utf-8 characters become ????????????
Post by: costis on April 09, 2008, 09:28:12 am
Hi Pete!
We do use both SUSE and Win-XP-SP2. SUSE will be our final target.
We face this problem on both OS's. We have only one correct working shop
right now, and this is on a Win system.

When we write greek into the customers table, with phpMyAdmin, and load the customer's data
to either konakartadmin or konakart, the Greek utf8 letters appear on screen, but as soon as we
edit the data and save they turn to question marks..... King Midas must have had a similar feeling.... :'(

Title: Re: utf-8 characters become ????????????
Post by: pete on April 09, 2008, 10:12:19 am
Since you have one working shop maybe you can spot what is different between the working one and the one that doesn't work ? There should be some clues there.
Title: Re: utf-8 characters become ????????????
Post by: costis on April 09, 2008, 11:19:04 am
Hi Pete!
have a nice morning!! We've been checking everything so far. We do have one question....
is it preferable to use InnoDB or mySQL? Does it make any difference for Konakart?
Title: Re: utf-8 characters become ????????????
Post by: pete on April 09, 2008, 11:42:03 am
InnoDB since it supports transactions.
Title: Re: utf-8 characters become ????????????
Post by: costis on April 09, 2008, 01:40:20 pm
Imported the database from the working Windows installation to the SUSE system. Greek characters went through to the customers-panel, but again, saving turned them to question marks. All settings are all identical.

A mickey mouse program to connect via jdbc to the database works correctly.






Title: Re: utf-8 characters become ????????????
Post by: kate on April 09, 2008, 02:37:51 pm
Hi Costis,

We have many users of KonaKart who use non-Western characters so we do know that it can support this.

Invariably the problem will be with the database configuration.

I just made a change to the configuration on the database being used on our demo application to ensure that UTF-8 is the default/server character set (evidently it's not enough for just the database to have utf-8 encoding).

You mentioned that you could not save Greek characters in our demo app earlier...   In the screen images below I have saved some Greek characters, and some Chinese for good measure (one is from the Welcome Mail that is sent and another on the Account Information screen).  (NB. I copied and pasted the Greek and Chinese so I'm not at all sure what I've written;  I hope it's not inappropriate language :-)).  Perhaps you could try to do the same and see if you get it to work this time?

I suggest that you check your MySQL configuration again and ensure that your encoding is defined correctly... I added these lines to my.cnf which seemed to do the trick for me:

[client]
default-character-set=utf8

[mysql]
default-character-set=utf8

[mysqld]
default-character-set=utf8
character-set-server=utf8

Kate
Title: Re: utf-8 characters become ????????????
Post by: costis on April 09, 2008, 05:44:20 pm
You made my day !!! Thank very much both of you for your time !!! Looks like we are getting rid of our question marks !!!
Now we have only exclamation marks, but this time on purpose !!! "Ελληνικό" means just Greek so don't worry  ;D

I'll have to learn Chinese to tell you about the second phrase !!!

Greetings
Costis
Title: Re: utf-8 characters become ????????????
Post by: kate on April 09, 2008, 05:49:59 pm
That's good news ...  and thanks for the translation :-)
Kate