jQuery - Trigger click event on links with spacebar?
- by Herb Caudill
It looks like in most browsers, an <input type="submit"> treats both [spacebar] and [enter] as a click, but an <a> link only treats [enter] as a click.
My app uses a number of links formatted to simulate buttons, so a user that is accustomed to tabbing to a button and pressing [spacebar] will be frustrated.
This bit of jQuery solves…