I want to get the return value for hid and show div after form submit success
<form id='form1' action='api.php' method='post'><input ></input></form>
<div id='layer1'></div>
I tried: Js
$('#form1').submit(function(e){
e.preventdefault();
$('#layer1').show();
});
It doesn't work. Is there anythings that I should return in the api.php? As I am using php5.2 I cannot using something like formdata to upload image when doing form submit.
Can anyone help?