File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
The moose likes HTML, CSS and JavaScript and the fly likes AJAX and php upload function. Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Engineering » HTML, CSS and JavaScript
Bookmark "AJAX and php upload function." Watch "AJAX and php upload function." New topic

AJAX and php upload function.

Justin Fox
Ranch Hand

Joined: Jan 24, 2006
Posts: 802
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?


Justin Fox

You down with OOP? Yeah you know me!
Eric Pascarello

Joined: Nov 08, 2001
Posts: 15385
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.

Justin Fox
Ranch Hand

Joined: Jan 24, 2006
Posts: 802
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
I agree. Here's the link:
subject: AJAX and php upload function.
It's not a secret anymore!