Win a copy of Re-engineering Legacy Software this week in the Refactoring forum
or Docker in Action in the Cloud/Virtualization forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

AJAX and php upload function.

 
Justin Fox
Ranch Hand
Posts: 802
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
ok, I'm passing the user's path to a file they want to upload to
a php page in the url, and I can't get my upload function to actually upload the file.

Is this way possible? or am I stuck using the standard upload form and having to send it to a php page with post?

Thanks,

Justin Fox
 
Eric Pascarello
author
Rancher
Posts: 15385
6
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Ajax can not upload files. If you look at Ajax solutions for uploading, you post a form to a hiden iframe and handle it that way.

Eric
 
Justin Fox
Ranch Hand
Posts: 802
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
yea I googled it and found out .

So I know that it is immpossible to just use strictly ajax to upload a file, but why?

is it because the upload steps in php make a temporary copy of the file on the server?

or what?

Thanks for the info,

Justin Fox
 
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic