I have Textbox and Button (Next and Previous) displayed in Lightbox.
Currently my page is reloading upon clicking the Enter key.
I dont want this to happen.
What i want is, when i click the Enter key, the "Next" button should be clicked without page reload which resides back of lightbox.
I used the following code, but both reload and click on Next button are happening:
$("input").bind('keyup', function(event){
if(event.keyCode == 13){
$("#nextbtn").trigger('click');
}
event.preventDefault();
return false;
});