Currently working on a script to show the progress of an upload using PHP and AJAX. How would this be possible? Because my script doesn't seem to work, tried something like this:
<form method="POST" id="uploadForm" action="<?=$_SERVER['PHP_SELF'];?>" enctype="multipart/form-data" onSubmit="uploadProg()"> <input type="file" name="uploadfile"> <input type="button" value="Upload File!" name="upload" onClick="document.forms['uploadForm'].submit();"> </form> <div id="uploadProg"> </div>
But upon submitting the form, the page refreshed and the uploadProg() ajax function ( which calls the PHP script to upload the file ) was not executed..
Could someone please help me?
Thanks in advanced!


Sign In
Create Account


Back to top









