News:

You may pay someone to create your store, or you visit our seminar and become a professional yourself with the silver certification

Main Menu

Translate : Please select an option

Started by Mister Paul, January 11, 2019, 22:17:52 PM

Previous topic - Next topic

Mister Paul

Hi,

I use an localized version of VM, but for children products but I cant get any translation for "Please select an option"

This is positioned just above the scroll down menu containing all chidren. But I can't find where I could change that content.
I tried to add: VM_CUSTOM_FIELD_VARIANT="My Translation" in /language/overrides/fr-FR.override.ini
But that doesn't work...

Where do I have to modify the code?

Thanks for your help
Paul

jjk

"Please select an option" is not a string in the VM3 language files. For the child products the original reads "Choose a variant".
I usually use the free Notepad++ editor's "Find in files" search feature to locate language keys and/or strings.
But you may also find the corresponding language key if you go to the Joomla overrides, click the 'New" button and then search for the string in the provided search form.
Non-English Shops: Are your language files up to date?
http://virtuemart.net/community/translations

Jörgen

It is a text found in the file:
jquery.validationEngine-en.js

On line 10:
(function($){
    $.fn.validationEngineLanguage = function(){
    };
    $.validationEngineLanguage = {
        newLang: function(){
            $.validationEngineLanguage.allRules = {
                "required": { // Add your regex rules here, you can take telephone as an example
                    "regex": "none",
                    "alertText": "* This field is required",
                    "alertTextCheckboxMultiple": "* Please select an option",
                    "alertTextCheckboxe": "* This checkbox is required"
                },


There should be a .js file in Your language, check "com_virtuemart/assets/js/languages"

Jörgen @ Kreativ Fotografi
Joomla 3.9.18
Virtuemart 3.4.x
Olympiantheme Hera (customized)
This reflects current status when viewing old post.

Mister Paul

Thank you.

For now I have 3.4.0 Virtuemart version. I know that I have to update... but I have to clean other stuff before.

In this version there is this string in jquery.validationEngine-en.js
                    "alertTextCheckboxMultiple": "* Please select an option",

It's well translated in jquery.validationEngine-fr.js
                    "alertTextCheckboxMultiple": "* Choisir une option",

I have selected French in Virtuemart Configuration / Language Settings / Shop Language
But this string is not displayed (only the english version is shown).

What could be the problem?

jjk

Quote from: Mister Paul on January 12, 2019, 10:28:11 AM
What could be the problem?

Might be a cache problem. Did you try to clear all Joomla/VirtueMart cache and browser cache already?
If that  doesn't help, it could be a language configuration problem. Are your products stored in database tables with a _fr_fr suffix?
Non-English Shops: Are your language files up to date?
http://virtuemart.net/community/translations

Mister Paul

#5
- It's not a cache problem as I clean it regularly and use the no cache option for my browsers during development
- And yes all the products are stored in virtuemart_products_fr_fr table

By the way there's only 1 string not translated on the page. See:
https://www.cjoint.com/data/IAmkpEcmTHU_Capture-2019-01-12-à-11.14.18.jpg

I was wondering if that could be a template problem, but I tried Protostar - Default:
same problem...

jjk

Can you post a screenshot of your custom field settings at Product [Edit] > 'Custom Fields' tab?
Non-English Shops: Are your language files up to date?
http://virtuemart.net/community/translations

Mister Paul

You pointed it:
it was a custom field named "Please select an option"

Thank you very much!
;)