I want enter to be pressed so the focus changes from the current to the next input. I've done this but i'm having a problem. The form submits when enter is pressed.
$('.length_input input[type=text], .qty').keypress(function(event) {
if(event.which == 13) {
//enter pressed
active($(this));
}
});
How do i allow enter to be pressed on inputs but prevent the form for submitting? I have a submit button to submit the form.