I had a form that when I clicked on submit it was submitted. Then that form hid and the result of action page showed in div with classname=dig.
dig
It was worki
$(".done").click(function(e) { var dig=$(this).parents('.dig'); var url = 'http://seller.ir/test' $.ajax({ type: "POST", url: url, data: $(this).parent('.formi').serialize(), success: function(data) { $(dig).empty() $(dig).html(data) } }); e.preventDefault(); });