I want to send all input in a form with ajax .I have a form like this.
can you try this :
function f (){ fname = $("input[name='fname']").val(); lname = $("input[name='fname']").val(); att=form.attr("action") ; $.post(att ,{fname : fname , lname :lname}).done(function(data){ alert(data); }); return true; }