Wednesday, 15 May 2013

HTML/JavaScript: Page's focus -


I have a shopping cart-like form when a user clicks on the page, in any case, The "Delete Item" button is focused, therefore, if the user clicks elsewhere and the press enters, the items are removed from their cart. It only happens in IE.

What can be done with it? How can I ensure that when this button is actually clicked, then this button is only focus?

Is it that you have the deleted buttons the only button in your form? If so, IE will treat it as a submit button and whenever it is pressed it will be pressed.


No comments:

Post a Comment