Results 1 to 7 of 7

Hybrid View

  1. #1

    Default UTF8 some Japanese char are question marks ??

    I am spinning over this one.... I have a Japanese language site with Japanese package by Crystal Koi installed several years ago on 1.3.8. Everything has worked fine until I upgraded to 1.5.1 and went live.

    Upload via ftp
    PHP - 5.2.17
    MySql - 5.0.96-community-log


    It seems the Japanese language translations/php files are showing ok, but the database info is not fetching correctly and getting ?????.

    All DB collation is correctly set at utf_gen_ci, english.php files in admin and includes are set to utf8, I've added the db_char_set.php file in extra configs, and set utf8 in the query_factory.php file.

    The Japanese characters show in the db tables. When I change a menu item to Japanese in the catalog/products manager, it shows correctly.

    I have thousands of products/descriptions and a large amount of customer, order and other info. I certainly don't want to go back and input manually.

    I would appreciate any suggestions. (I do have a backup of 1.3.8 site and db).
    You can't wait for inspiration. You have to go after it with a club.
    "Jack London"

  2. #2
    Join Date
    Jan 2004
    Posts
    66,446
    Plugin Contributions
    81

    Default Re: UTF8 some Japanese char are question marks ??

    Quote Originally Posted by studiotucker View Post
    I've added the db_char_set.php file in extra configs, and set utf8 in the query_factory.php file.
    Please explain EXACTLY what you did for both of these. What you wrote is generic, but your exact specifics are critical.
    And there should be NO need to touch query_factory.php Again, exact details are needed.
    .

    Zen Cart - putting the dream of business ownership within reach of anyone!
    Donate to: DrByte directly or to the Zen Cart team as a whole

    Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
    Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

  3. #3

    Default Re: UTF8 some Japanese char are question marks ??

    You know, I think I just found the problem.....

    I did put a new file (as I saw mentioned in other support threads) /extra configures/m_db_charset.php in both admin and includes.

    Problem was I failed to put utf8 in the string....<?php define('DB_CHARSET', 'your_charset_here');....a senior lapse..... I thought I had, but when you replied I checked the file again and saw I had not changed it. Changed and now the JP is showing fine throughout the site........whew.

    Thanks for the input about query_factory. I'll change back....time for a bottle of sake!
    You can't wait for inspiration. You have to go after it with a club.
    "Jack London"

  4. #4

    Default Re: UTF8 some Japanese char are question marks ??

    I have to say, I am surprised that I needed to add a separate file with one short line of code to get UTF8 to show correctly on all pages of the zencart platform. It's a pretty international platform and I don't understand why this can't be automatically included???

    For anyone else who stumbles here looking for a solution, I followed a solution I found somewhere else and it worked.

    Create a new .php file name it anything(?), I named mine "my_db_charset.php". Include in the file, one line of code <?php define('DB_CHARSET', 'utf8'); save and upload to your extra-configures directory in both includes and admin/includes.

    I required utf8, but I would assume that you could use any charset that you need zencart to conform to and would just replace the utf8 in the line of code with yours.
    You can't wait for inspiration. You have to go after it with a club.
    "Jack London"

  5. #5
    Join Date
    Jan 2004
    Posts
    66,446
    Plugin Contributions
    81

    Default Re: UTF8 some Japanese char are question marks ??

    Quote Originally Posted by studiotucker View Post
    I have to say, I am surprised that I needed to add a separate file with one short line of code to get UTF8 to show correctly on all pages of the zencart platform. It's a pretty international platform and I don't understand why this can't be automatically included???
    It IS automatically included. For new installations, not for upgrades.

    When you do a new install of Zen Cart v1.5.0 or newer, the configure.php file will already contain a define for DB_CHARSET.
    If your upgrade involved doing a new install of Zen Cart, then you would also have had that automatically. But, since you chose a different approach for upgrading, you've had to apply your own bandage to get to the same end result.
    .

    Zen Cart - putting the dream of business ownership within reach of anyone!
    Donate to: DrByte directly or to the Zen Cart team as a whole

    Remember: Any code suggestions you see here are merely suggestions. You assume full responsibility for your use of any such suggestions, including any impact ANY alterations you make to your site may have on your PCI compliance.
    Furthermore, any advice you see here about PCI matters is merely an opinion, and should not be relied upon as "official". Official PCI information should be obtained from the PCI Security Council directly or from one of their authorized Assessors.

  6. #6

    Default Re: UTF8 some Japanese char are question marks ??

    Thanks Doc.
    You can't wait for inspiration. You have to go after it with a club.
    "Jack London"

  7. #7

    Default Re: UTF8 some Japanese char are question marks ??

    A follow up....I have checked through the site and the problem seems to be only with the product catalog menu and item pages on the front end. Headers, define pages and such are showing fine......headers and menu in admin are fine, but the customer , order, catalog, and product data are not showing correctly...
    You can't wait for inspiration. You have to go after it with a club.
    "Jack London"

 

 

Similar Threads

  1. Replies: 4
    Last Post: 2 Dec 2013, 07:43 PM
  2. Japanese Char not displaying properly on part of the webpages
    By gamenano in forum General Questions
    Replies: 2
    Last Post: 5 Nov 2012, 01:56 AM
  3. Greek characters showing as char$ codes at some places only
    By andreasy in forum General Questions
    Replies: 19
    Last Post: 15 Dec 2010, 12:23 AM
  4. some char in product desc is truncating
    By svakanda in forum General Questions
    Replies: 1
    Last Post: 16 Jun 2009, 11:37 PM
  5. Japanese text outputs Question Marks
    By beerlabelbuilder in forum Addon Language Packs
    Replies: 9
    Last Post: 1 Mar 2009, 12:33 AM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
disjunctive-egg