1

In my having two stores France and German.I want to validation error messages with their particular languages.How can I do it with my Js script?

My code

       <label for="sample" class="required"><?php echo $this->__('Sample');?><em>*</em></label>
       <input type="text" name="sample" id="sample" class="input-text required-entry" >
       <label for="test" class="required"><?php echo $this->__('test');?><em>*</em></label>
       <input type="text" name="test" id="test" class="input-text required-entry validate-digits"  maxlength="4" >

Js Code

     //<![CDATA[
   var brochureform = new VarienForm('form');
    //]]>  
0

If this is within a custom module you are developing add it to the translation files of that module and register them in config.xml. Inchoo explains how to do that.

If this is within a custom theme of yours then you could add this to your translate.csv files of that theme. Templatemonster has a help article about that.

From what I see of your posted code your JS code has no influence on the translations as they come from PHP.

|improve this answer|||||

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.