|
hi guys,
just joined the site. i've just come across this requirement for a job and thought i'd add my bit. on another site i had successfully ran a php file externally using AJAX. The job of the php page was to send an email which is does. However when i tried the same method to upload a file it didn't work. I put this down to the fact that, on the email sending example it was merely getting the values of the form, whereas on the file upload attempt it didn't quite work. i had tested the upload php page with a standard form submit method and it worked fine, any clues on why?
when uploading a file with php and you have the attribute enctype="multipart/form-data" on a form, is the only way this extra data transferred by doing a standard sumbit? i'm thinking yep as on the php upload page we don't actually use $_REQUEST and use $_FILES instead?
From reading the thread i've cottoned onto the idea using a hidden iframe and will get back to you with my results.
thx for any thoughts or confirmations
|