javascript - jQuery form submition prevention not working -


i have form submit button trying intercept data for.

i've not had trouble in past there seems in particular set wrong.

i have form:

<form id="myform">     <!--inputs-->     <!--...-->     <input type="submit" value="search"> </form> 

i'm using js:

$(document).on("submit", "#myform", function(e){     e.preventdefault(); }); 

and i've tried:

$(document).on("submit", "#myform", function(e){     return false; }); 

and both times form still submits. i've put in function serializing form data in event listener, , function fires, know submit event listener working, it's not preventing it. there no errors in js console, , nothing else behaving improperly.

i'm using jquery 1.9.1 , jquery mobile 1.4.2.


Comments

Popular posts from this blog

javascript - how to protect a flash video from refresh? -

visual studio 2010 - Connect to informix database windows form application -

android - Associate same looper with different threads -