Changing Magento Validation

To change magento checkout validation, you can change the class of the form field to use one of the other validation methods present in js/prototype/validation.js. Just open that file and scroll down to see the methods available. Search fo r this Validation.addAllThese and you’ll see the methods below. Then open up /app/design/frontend/default/YOUR THEME/template/checkout/onepage/billing.html then change the class. For example if the class is class=”required-entry input-text” change to class=”required-entry validate-phoneLax”. This will now change the validation from simply checking if a value is present to actually checking the format.

This entry was posted in Uncategorized. Bookmark the permalink.

Leave a Reply

Your email address will not be published. Required fields are marked *

*

You may use these HTML tags and attributes: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>