When a visitor enters a string in the quantity field of the “Add to Cart” input box, Magento doesn’t throw an error, but instead accepts the string and interprets it as the quantity “1”. How can I change this so that validation recognizes strings as invalid input? There already exists an onClick function on the “Add to Cart” button, so I don’t think I can attach my own validation code to that button.
When a visitor enters a string in the quantity field of the Add to
Share
There is a setting at a product level which is called “Maximum Qty Allowed in Shopping Cart” that may be set to one.