I got the image file to upload to the server without refreshing the entire page by using an iframe, below is the code.
Code:
<form name="ImgForm" id="ImgForm" enctype="multipart/form-data" method="post" action="image_upload.php" target="imgUploadFrame">
<label class="label">Upload Picture:<br/>
<input type="file" name="imgFile" id="imgFile" /><input type="submit" name="saveImg" value="Save" /></label>
</form>
<iframe name="imgUploadFrame" id="imgUploadFrame"></iframe>
However, I'm having trouble with displaying the image once the file is successfully uploaded.
AJAX could probably be set up with some javascript to monitor the progress of a request or repeated request for the image uploaded as an image element object.
Could you give an example of the above?
Bookmarks