Customize the validation error messages of validation.js in magento -
in magento application checkout page , displays error message using validation.js file.
when click continue in new billing address without entereing value displays error message this required field..
i want change message corresponding field name .

instead of error message need display first name required field..
how can ?
edit
this input box located in customer/widget/name.phtml as:
<input type="text" id="<?php echo $this->getfieldid('firstname')?>" name="<?php echo $this->getfieldname('firstname')?>" value="<?php echo $this->escapehtml($this->getobject()->getfirstname()) ?>" title="<?php echo $this->getstorelabel('firstname') ?>" maxlength="255" class="input-text validate-firstname" <?php echo $this->getfieldparams() ?> /> 
this output.
you can create class in validation.js file validate-firstname , add in validation.js file
['validate-firstname', 'first name required field.', function(v) { return !validation.get('isempty').test(v); }], search validate-alpha validation line , after put code in js file , add validate-firstname class in firstname input field.
Comments
Post a Comment