here's the situation
Within a single form 1) User clicks on the 'browse' button, which opens a dialog to choose an image file to upload. i.e.
input id='img_upload' name="ufile" type="file" value="Browse"/>
2) With file selected, user then clicks a button 'Upload file' button, which calls a js function i.e.
input type='button' id='uload' class='save2' value='Upload file' onclick='upload_img()' > </input>
What I would like upload_img() to do is send the contents of the browse via POST through something like AJAX to a .php file called image_upload.php, which will save the img and output an tag displaying the img file. I have an iframe which displays the contents of image_upload.php
If possible, how can I access the contents of a 'browse' and send it through POST
Cheers!
EDIT Sorry I forgot that a strict subset of html is supported, so I had to remove the left most <