Monitoring File Uploads using Ajax and PHP
Conclusion
At this stage all of the required code has been implemented, meaning you should now be able to upload a file using the index.php file. Assuming your code all works correctly, the status of the upload should be displayed while it is uploading. Note that small files may upload so quickly you don't see any real-time updates.
While the code we implemented in this article does gloss over a few things (such as informative error handling), hopefully it does demonstrate our primary goal: how to monitor the status of a file as it is being uploaded.
The key points covered in this article included:
- How to install APC and configure it correctly for upload monitoring
- How to retrieve upload data from APC
- How to develop a class using Prototype JavaScript library
- How to send JSON data with PHP and receive it using Ajax
Other Options
- Download a PDF version of this article
- Put your PHP knowledge to the test with our online and iPad/iPhone quizzes
- View or post comments for this article
- Browse similar articles by tag: Ajax, APC, File Upload, JSON, PHP, Prototype, RFC 1867
- Read related articles:




