Results 1 to 4 of 4
  1. #1
    Join Date
    Oct 2011
    Plugin Contributions

    Default Japanese stopped displaying in cart, still displays in Admin

    Using 1.39 upgraded from 1.38 with the Japanese language pack elements from Crystal. Worked in 1.38, worked in 1.39.

    Added a 2nd store to the same database with different prepended string. 2nd store installed & worked with demo products. When I added the Japanese elements, for some reason the database collation didn't save as utf8_general_ci for the tables.

    So ran a process that updates all tables to utf8_general_ci. It appeared to work.

    But all of the Japanese no longer displays on the first site. However, it displays and edits properly on the admin for that site.

    The html headers generated include:
    <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "">

    <html xmlns="" dir="ltr" lang="ja">


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

    ... and the browsers correctly select utf-8 encoding, but the output is mangled.

    I'd assume my database data was mangled, but as I mentioned, it displays and edits perfectly in Admin.

    So I looked for differences between the japanese.php folder in the Admin section and the one in the main includes folder.

    The one in th Admin section has a header that says it's
    * @version $Id: english.php 7440 2007-11-17 21:51:35Z drbyte $

    The one in the main cart includes folder is the one from Shawn Ward and Seiji Matsumoto
    * @version $Id: japanese.php v1.2 CKD Shaun Ward/Seiji Matsumoto

    Any suggestions would be GREATLY appreciated at this point. Thanks.

  2. #2

    Default Re: Japanese stopped displaying in cart, still displays in Admin

    yes i am also facing the same problem so any third person could solve our problem there?

  3. #3
    Join Date
    Oct 2011
    Plugin Contributions

    Default Re: Japanese stopped displaying in cart, still displays in Admin


    1) the conversion also affected another MySQL program using the same database. Its fields were already labeled utf8_general_ci so I didn't expect them to be affected, but the tech support people said the data had been corrupted, and they fixed it...

    2) I found that I could copy the readable Japanese characters from my Admin area (for example, a product description) and paste them directly into the PHPMyAdmin fields... and it would fix them on the website!

    3) Once they looked good on the website and good in PHPMyAdmin, they became unreadable in ZenCart Admin. No kidding. So some difference in encoding between the Admin page and the MySQL database is going on, with the amazing result that I can have readable Japanese in Admin, copy/paste it into the same fields in the database, and get readable Japanese in the database and on the web pages but now I have unreadable junk in Admin.

  4. #4
    Join Date
    Oct 2011
    Plugin Contributions

    Default Re: Japanese stopped displaying in cart, still displays in Admin

    This was what caused the problem: 1.39 handles query encoding differently from 1.38 or future versions, as outlined here :
    To get the utf-8 to work properly, you need to insert a one-line php file into the the includes/extra_configures folder. The name can be anything, but the contents are the single line:
    <?php define('DB_CHARSET', 'utf8');

    I had put that into my includes/extra_configures folder, but NOT my admin/includes/extra_configures folder. So the main storefront was interpreting the database correctly, and the admin section was mangling it.

    Now, all my old customer data that looks mangled in the database (new stuff is fine) and USED to look correct in admin is mangled in admin. So I'm about to embark on the final cleanup of removing that key file again so things look good in Admin, copy/pasting them into the database directly to fix the data in the database, then putting the one line DB_CHARSET file back into the admin/includes/extra_configures folder so they look correct in Admin going forward.

    Key instructions I ignored that caused this mess:
    1) configure the database collation before installing the cart
    2) put the one-line file in BOTH the main AND the admin includes/extra_configures folders.

    Hope this helps somebody else.



Similar Threads

  1. CKD-Zen-Cart Japanese Pack
    By CrystalKoi in forum Addon Language Packs
    Replies: 55
    Last Post: 30 Apr 2011, 07:13 AM
  2. All images in category view stopped displaying in IE7/!
    By buddhaflow in forum General Questions
    Replies: 5
    Last Post: 16 Dec 2010, 04:05 PM
  3. Shopping Cart and Admin displaying incorrect date/time
    By behofmann in forum General Questions
    Replies: 1
    Last Post: 12 Mar 2010, 10:47 PM
  4. Japanese version zen-cart, price error
    By anewstone in forum Built-in Shipping and Payment Modules
    Replies: 6
    Last Post: 19 Dec 2009, 02:22 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
Zen-Cart, Internet Selling Services, Klamath Falls, OR