DrByte, I have the following problem: I have followed the steps to install a new, fresh ZenCart to be utf8 from the start, as described here: srw2d.com/sites/default/files/utf-8-zen-cartV1.3.8.pdf
I also noted the point that for ZC 1.3.9d WHich I am using, you should not modify the query_factory.php but instead create two new files called my_db_charset.php and put them in /yoursite/includes/extra_configures/ and /yoursite/admin/includes/extra_configures/ respectively.
Now: Having done all that and followed through with a new, clean installation without any problems, the result is this: Whether I try to open the front or the administrator back end, I just got the install page all over again, as if nothing had happened. When I remove those two files called my_db_charset.php the front end and back end show up just fine!
What is wrong here?
Now it seems to work fine, but I am afraid that when I next install a spanish language pack and start entering data in both english and spanish that things will get messy....
Thanks very much in advance for an answer.
Oh, and by the way: Obviously this alternative way of setting the db_charset in a separate file instead of modufying the query_factory.php obviously didn't work at all in my case: After giving the new and fresh database a look I found that all the tables had still been created with latin1 collation!
Now I have manually and painstakingly changed the charset of every field (where specified) in every table, plus the collation of every table to utf8_general_ci. Phuhh.... That's a lot of mouse clicks... I once came across a post that showed a way to do this with SQL scripts, but where was it when I needed it?
Anyways: I would still like to know what to do here, because even though I should be fine now, every time in the future that I add something that creates another database table, obviously I need to manually change this. Please, someone help??
If the system is completely ignoring the built-in code which properly sets the collation, then it's probably inheriting the collation from the database itself. Thus, changing the database's default collation and character set would be your required next step.
.
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.
Jack, that '?>' is not necessary: https://www.zen-cart.com/tutorials/i...hp?article=313
.
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.
Hi all. I have been successfully using Zen Cart for 2 years now....Me and my wife work at it full time, doing an online bicycle shop.
Anyway, I am about to build a separate shop and am trying to get the UTF-8 settings sorted.
I have 1.3.9 and so do not need to modify query_factory.php
I just can not understand what I am meant to do instead.... sorry for being so ignorant. I just find the instructions on this thread too brief/vague to get my head around.
----
Here are my questions regarding DRBYTES post/instructions....
----
DrByte said//
Create a new file for it: (((I do this by making a new file in smultron or text editor?)))
/includes/extra_configures/my_db_charset.php
Code:
<?php define('DB_CHARSET', 'your_charset_here'); (((so I type UTF-8 in this space between the apostrophes?)))
Do the same with: /admin/includes/extra_configures/my_db_charset.php
------
I hope that makes sense.....
Thanks DrByte! This was great help to us in fixing the correct display of our German language files.
I found the reason for blank store and admin pages in my case was a simple mixup of admin and store english.php files. Putting the correct files in place corrected the problem.
Bookmarks