A word of warning - Greek is severely broken in cs-cart

A word of warning:



Greek is severely broken in cs-cart, and I don’t mean that the translation is incomplete. Let me explain:



First, I noticed that during XHTML validation of the front-end, the ISO language code was “gr”, which is wrong, since there is NO language “gr”. The proper Greek ISO code is “el”.



Then, I also noticed that TinyMCE, while fully translated to Greek, it displays in English, even though I’m viewing the administration panel in Greek. Apparently, because cs-cart has the wrong language code for Greek, it tries to set the TinyMCE language as “gr”, which is wrong so TinyMCE defaults back to English.



Now these are just for starters, because there are other problems as well. For example, google.gr (the Greek version of google.com) does not index Greek pages properly because of the wrong language code “gr” that cs-cart sets on the pages.



I thought it might be easy to fix this by running an UPDATE on the SQL table with the Greek translation, but thats not a proper fix, because there are many MANY other pages that still have the “GR” value (products, categories, etc).



I’ll keep you posted if I find a solution to fixing the language code. I’ve opened a support ticket but so far I haven’t received a reply.

We were just starting to implement this - thanks for pointing out the issue. I didn’t realize the language code in the DB was being used to set the ISO language.

I am coding a custom template when I noticed this issue. Inside the template I found the code which uses Smarty tags to take the DB lang_code and change it to lower case.



At first, I thought I could get away with just changing the “gr” to “el” in the template itself, but then I noticed that this was wrong all over the place, including the admin panel.



Eventually, I found out that to correct this, we would have to change every lang_code DB column.



I’ve opened a support ticked and I was given a “quick hack” that wasn’t good enough, the support guy suggested to make an SQL dump and do a text search-replace, but that messed up many strings that are not related to the language code. So we have avoided this hack and waiting for a more proper solution.



I suggested to write a bunch of SQL “update xyz…” lines to properly find all the lang_code columns in all the tables and change those. I’m not sure if thats enough…

If you are running MYSQL 5.x can you do an update on rows using REGEXP or perhaps use a regular expression based search and replace on the dump?



Something like regex coach? or V-Grep on windows?



I’ll play around with it a little bit and see if I can come up with something reliable.

I just created a bunch of “UPDATE” sql statements and run them, I converted all “GR” to “EL” as they should be.



There is one bug in cs-cart’s SEO plugin, which still forces the SEO strings to use “GR”. I don’t know how it gets that, but I haven’t figured out a way to fix it. I’ve opened a support ticket but they haven’t replied yet.



If you don’t use the SEO plugin, then you shouldn’t have any other problem. Also, remember to rename the “gr.png” to “el.png” so the flag shows up correctly.