yeah, unfortunately you are both right... :-| In fact I was afraid to receive this answer...
Anyway, how can I upload the image just with js and without submitting the form? jQuery standard function ($.ajax) does not seem to allow a file/image as a file type... I also looked to some plugins and they allow just xml,json... Have you got any idea about what I can use? Thanks, Andrea On Sep 17, 6:53 pm, tlphipps <[EMAIL PROTECTED]> wrote: > You could certainly accomplish this with a little bit of AJAX thrown > in. > > Scenario: > - user selects image (using <input type='file'>) > - user clicks 'preview' button > - system submits selected image file via AJAX to server > - server processes image upload and stores file on server > - In the AJAX 'success' handler, create new <img> tag on page which > references newly stored image file on server. > > On Sep 17, 12:04 pm, config <[EMAIL PROTECTED]> wrote: > > > You can't view the file because of security restrictions. > > > A *long* time ago one could grab the path and call it with the file:// > > protocol, but this is now blocked in most (all?) browsers. Similarly, > > one can't write a path into the file input. > > > G.