HTML
<form id = "frm" action = "servlet">
<input type = "button" onclick = "return submit()">
</form>
script
<script>
function submit(){
$j('#frm').ajaxForm({
dataType : 'json',
url: $j('#frm').attr('action'),
enctype: "multipart/form-data",
success : function(result){
alert('success');
}
})
document.getElementById('frm').submit();
</script>
I want to see the result. But I do not see success.
Why not?
Comments
Post a Comment