Well, after downloading it, you can use javascript to put it on the html page.
I'm not quite sure what your question is though
EDIT:
So, the html form on your page:
<form action="imageUpload.php" method="post" enctype="multipart/form-data" target="upload_target" onsubmit="jupload();" id="form1" > <div style="visibility:'hidden';" class="imageholder"> </div> <input type="file" name="imgfile" /> <input type="submit" name="uploadButton" class="upbtn" value="Submit" /> </form>
Javascript code (JQUERY) for uploading and adding images:
function jupload() { $(".imageholder").append('<img src="./images/loading.gif">'); } function juploadstop(result) { if(result==0) { $(".imageholder").html(""); }
php code:
<?php $target = "http://www.mockcourt.org.uk/user/htdocs/pics/2012/"; $target = $target . basename( $_FILES['uploaded']['name']) ; $ok=1; if (move_uploaded_file($_FILES['uploaded']['tmp_name'], $target)) { $result=$target; } else { $result=0; } ?> <script language="javascript" type="text/javascript"> window.top.window.juploadstop(<?php echo $result; ?>); </script>
Indra source share