keypress
$(document).keypress(function(e) {
if ((e.which && e.which == 13) ||
(e.keyCode &&e.keyCode == 13))
{
// do something
}
});
mean mike
On Dec 17, 2:03 pm, "[email protected]"
<[email protected]> wrote:
> Hi,
>
> I would like to capture the event of pressing enter anywhere on the
> page, even if the focus of the mouse cursor is not on a text field.
> What event/element am I looking at?
>
> Thanks, - Dave

