VirtueMart Forum

VirtueMart 2 + 3 + 4 => Language/Translations => Topic started by: hofitd on July 31, 2012, 16:40:44 PM

Title: Countries translation
Post by: hofitd on July 31, 2012, 16:40:44 PM
Hi,

How do I translate the built in countries names to different language?
I couldn't find it nowhere...

Thanks
Title: Re: Countries translation
Post by: bytelord on July 31, 2012, 16:52:06 PM
Hello,

On configuration --> Countries select the country you want to translate and change the Country name.
This is only if you use one language.

Hope it helps.

Regards.
Title: Re: Countries translation
Post by: jjk on July 31, 2012, 22:09:09 PM
The country names and the country's state names are stored in the database, not in translatable ini files. But I think in most cases it is also ok to change the country names to the language used in each individual country if your site is multilingual, because usually the customers will look for an entry in the the same language he/she is using to look at your site. You could also add an additional country name in a second language. But in this case you would have to set up additional country-name specific shipping and payment methods, too.
Title: Re: Countries translation
Post by: rvbgnu on August 01, 2012, 03:17:42 AM
Arrrrgggg.... I haven't check that yet.... So in a multilingual web site, everyone will have the countries in English ?? Would it better to use country ID for all shipment and payment method, instead of name ? Then it will great to have the country list in the .ini file, so every language could have their translation. How does the VM Dev team stand on this?
Title: Re: Countries translation
Post by: jjk on August 01, 2012, 09:11:28 AM
I think on my bilingual site I'll stick with my native language country name plus all other country names in english. If you add country names in their orginial language and character encoding, you would have trouble reading some of them in your order forms. Imagine somebody from Russia or China orders a product in your english language cart and adds his address in his native language (from his russian or chinese keyboard).
A small example of what would happen is shown in the screenshot below (note the native language strings).

[attachment cleanup by admin]
Title: Re: Countries translation
Post by: rvbgnu on August 01, 2012, 12:11:02 PM
I do agree, jjk, to avoid character encoding issue and so. What I meant in "to have the country list in the .ini file, so every language could have their translation" is: every language of the website, in the Joomla Language settings (language packs and content) and so in the VM config. So for an English and French website, the country list will be in English in the English pages (session variable lang=en), and in French for the French users. Reproducing the Joomla behavior.
Or instead of .ini file, it could be like the multi lingual feature in VM. It is missing in some parts IMHO, and not very easy to use intensively, but, it is implemented and working, so I am happy!
I think the goal is to provide a full user interface in the languages available in the web site.
Title: Re: Countries translation
Post by: alatak on August 01, 2012, 13:04:45 PM
Hello,

Yes we had discussed about that some time ago.
Myself i don't really like the solution that we use : to have keys to make some items multilingual, like in the order status. It is easy to do, and implement, but for the end user, i don't think it is very ergonomic...

The problem at the moment, afaik, are for the countries and for the currencies name.
Title: Re: Countries translation
Post by: jjk on August 01, 2012, 13:31:17 PM
Additional comment to the previous post: The best idea would be to convince the Joomla devs to implement countries and currencies in ini files, so every extension could use it.
Title: Re: Countries translation
Post by: hofitd on August 02, 2012, 13:01:13 PM
As I see it, I hate to see a different language on a site with deafult language. for example - I;m from Israel and we use Hebrew - and in many cases  I see english strings on websites just beacuse someone was to lazy to translate it - I hate it!
On my sites the entire site should be using the same language.

I thinks I've seen a thread that suggested to implement  a String key and add it to the ini file. It wasn't for the countries, but for something else.
Will it work in  this case?
It's not the best solution but I can deal with it for now.
And I do think you should find a solution for this.
Title: Re: Countries translation
Post by: jjk on August 02, 2012, 13:30:13 PM
Quote from: hofitd on August 02, 2012, 13:01:13 PM
Will it work in  this case?
No, but if your site is in Hebrew and want to sell within Israel only, you could change the english language country name to Hebrew in the VM2 configuration or database table and unpublish the other countries in VM2 configuration.
Title: Re: Countries translation
Post by: hofitd on August 05, 2012, 07:47:15 AM
and if I want to sell in Europe and in the US?
what you're saying is that there is no solution for this in multilingual website...
Title: Re: Countries translation
Post by: alatak on August 07, 2012, 09:49:25 AM
Hello,

I have done the countries translatable. It will be available in the next version (the current one is 2.0.8.e).
The countries names are in file called com_virtuemart_countries.ini. You just have to translate them now :)
Title: Re: Countries translation
Post by: hofitd on August 08, 2012, 11:43:49 AM
Perfect! thank you!

where is the ini file?
Title: Re: Countries translation
Post by: jjk on August 08, 2012, 12:29:16 PM
Quote from: hofitd on August 08, 2012, 11:43:49 AM
where is the ini file?
Attached below

[attachment cleanup by admin]
Title: Re: Countries translation
Post by: hofitd on August 08, 2012, 12:50:56 PM
great

does that include the states names?
Title: Re: Countries translation
Post by: alatak on August 08, 2012, 13:04:57 PM
Hello,

we have changed something. You will not need to update the database.

The states translatable?
why should they be?
They are in the original language already (In greek for grece)
Title: Re: Countries translation
Post by: hofitd on August 09, 2012, 10:19:04 AM
Hi

I already updates the DB..

what do you mean? Is there already an ini file for the states?
Title: Re: Countries translation
Post by: alatak on August 09, 2012, 10:52:16 AM
Hello,

If you have updates the database, sorry then, we found a better solution that did not need the update.
You can find the correct query in the file /administrator/components/com_virtuemart/install/install_required_data.sql
to put back the old data. look at the query for the #__virtuemart_countries.

Concerning the states, i was just wondering if there was any need for that. But may be there is one.

I fear that for the states, it need the help from greek people to solve, because some states code are at the moment in the original language like for the greek states code.  example: ΜΕΣ.
I guess that in Greece, the also have states code with non greek letters? i don't know.
The russian states code are ok.

Concerning the translation, there are 2 issues that we have not fixed yet. We wil do it for another release: states and currency.

Currency  will be easy to solve.

Title: Re: Countries translation
Post by: hofitd on August 09, 2012, 10:56:16 AM
Well, I don't know about grece..

In israel we have israel, Gaza strip and other (or something like that) - so it's ridiculous  to write the country name "israel" in hebrew but the states are still in english...
Title: Re: Countries translation
Post by: alatak on August 09, 2012, 11:02:59 AM
Hello,

Yes you are right,

but at the moment you don't have in the db the israel states?
You have done it manually probably. You could have entered them in Isrealian?

But ok, i will do it, but not for the next release.

Title: Re: Countries translation
Post by: hofitd on August 09, 2012, 11:07:22 AM
Israelian? :-)
Hebrew..

If I change it in the DB will it change it in any language or just in hebrew?
Title: Re: Countries translation
Post by: alatak on August 09, 2012, 11:31:53 AM
hello,

oops sorry, ofc hebrew :)
Title: Re: Countries translation
Post by: hofitd on August 09, 2012, 12:34:20 PM
:-)
so what about...?

Quote from: hofitd on August 09, 2012, 11:07:22 AM

If I change it in the DB will it change it in any language or just in hebrew?
Title: Re: Countries translation
Post by: alatak on August 09, 2012, 13:04:29 PM
Hello

If you change the state table , and write the states name in hebrew, they will be displayed in hebrew :)
Title: Re: Countries translation
Post by: hofitd on August 09, 2012, 13:33:34 PM
in all languages?

If it's a multilingual site what will happen?
Title: Re: Countries translation
Post by: alatak on August 09, 2012, 13:35:01 PM
No, as i said previously at the moment the states are not translatable. This will be done for another release.
Title: Re: Countries translation
Post by: iMonkeys on September 05, 2012, 10:52:45 AM
For those looking for dutch translation of the countries ini-file; take a look at this topic:
http://forum.virtuemart.net/index.php?topic=107254.0
Title: Re: Countries translation
Post by: alatak on September 05, 2012, 12:59:22 PM
Hello,

Ok , I have added the file.
Title: Re: Countries translation
Post by: Dakure on May 12, 2013, 16:36:18 PM
Hi, I can not translate the countries...

I am under 2.0.14 ... joomla 2.5.8

I uploaded en-GB.com_virtuemart_countries.ini and es-ES.com_virtuemart_countries.ini in my case.

I translated also xxx_virtuemart_countries table and still I don t have the word "Spain" in the correct language.

I checked all the languages files ( also from administrator ). Checked all the database allready... Edited the Info from the country in virtuemart backend also ...

I need to change somehting else to get the translation? or how to make the ini files to work please?

thanks
Title: Re: Countries translation
Post by: jjk on May 12, 2013, 17:27:28 PM
You should not translate the xxx_virtuemart_countries table. I would suggest to install the original one again. Your versions are pretty old already. As far as I remember, there was no es-ES.com_virtuemart_countries.ini supplied with version 2.0.14. Perhaps you should consider to update to latest versions of Joomla 2.5.11 and VirtueMart 2.0.20b. I recently uploaded a spanish language file including translated countries here:
http://forum.virtuemart.net/index.php?topic=115198.msg388154#msg388154
Basically this language pack is for 2.0.16, but it's still ok for 2.0.20b.
Title: Re: Countries translation
Post by: Dakure on May 13, 2013, 10:11:05 AM
oh thanks... :)

I am in the middle of finishing this ... and is hard to update at the moment.

I downloaded the spanish.ini file somewhere... maybe from you ... and translated allready the countries table, as I told ... and this is crazy ... no way.

I checked all the database... checked all  my joomla and virtuemart files (more than 10.000)  looking for the word ... no way.

Entering the countries tab in VM . I can see  : España   (Spain) [Estates] ... All the names between parenthesis ara still in English...

This can be the source? From where is loading this? Any clue? If not this ...I can do something else?


Title: Re: Countries translation
Post by: alatak on May 13, 2013, 10:29:23 AM
Hello
QuoteI downloaded the spanish.ini file somewhere... maybe from you ... and translated allready the countries table, as I told ... and this is crazy ... no way.
You do not need to translate the country tables.
If you have uploaded the file here:
administrator/language/es-ES/es-ES.com_virtuemart_countries.ini

when the front end is in spanish, the the countries should be displayed in spanish
the same for the back end: if the backend is in spanish, your countries should be displayed in spanish

Title: Re: Countries translation
Post by: Dakure on May 13, 2013, 10:41:27 AM
Thanks Alatak  :) but  this is not working for me under 2.0.14 as I told ...  I remember you said must work under 2.0.10 that s why I am asking.

I Really just checked the table, not changed in any way because was correct spelled ESPAÑA there. I am sure I didn t nothing wrong with this.

Anybody knows from where the word (spain) is loaded in the countries VM tab? as displays default in parenthesis: España  (Spain) [Estates]

I think is my last chance ...

help apreciated :-\
Title: Re: Countries translation
Post by: alatak on May 13, 2013, 10:58:47 AM
Hello
Quotethis is not working for me under 2.0.14 as I told
it does work for that version. I have checked.
I have set up a website with VM 2.0.14 with spanish.
Transferred a file administrator/language/es-ES/es-ES.com_virtuemart_countries.ini
and the countries are in spanish

Title: Re: Countries translation
Post by: Dakure on May 13, 2013, 11:14:14 AM
Sorry, this is only happening to me ...
I am sure it works since 2.0.10 don t get me wrong.
I was trying to find a walkaround with this cause this only happens to me in this site.  Something is wrong. Maybe is not the version it says...
With a fresh installation it works like a charm ... I will begin from scratch don t wanna waste time of people.

Thanks to all. :D
Title: Re: Countries translation
Post by: adventure1 on June 06, 2013, 01:47:47 AM
Sorry for my English.
I had a problem with the name of my country in the address, which is to show in English, not my native language. Solutions to this problem have already searched a long time and I could not find anywhere as to why this is happening. In the end I found.
You have to change the name of the country in the configuration store -> countries (look for our country and press on the name, which is in English and change it into our language). That's all.
I hope that helped.