PHP Resumable Download Server
I wanted to add a download section to my site, but at the same time keep statistics of the files downloaded. So made a little PHP script to act as a download server.
This little script became a little larger when I added support for partial file downloads. I noticed that many comments in the PHP manual and other sources described the method wrong. For instance, many of them announced to accept multiple byte ranges while that was not the fact. And they also tended to not handle the requested byte range according to the HTTP 1.1 specifications.
Now, I'm never pretending this is a complete implementation or free for issues. But it should work very well and I've tried to make it behave to the specifications.
Features
- Serves files from a file repository.
- Makes sure no files outside the repository is served.
- Lists files if a directory is requested.
- Supports partial file request allowing users to pause or accelerate downloads.
- Logging function to keep statistic over the file downloads. (Needs configuring to work.)
Known Issues
- Files larger than 2GB might give unexpected results on platforms that use 32-bit integers. This is because it might affect the calculation of filesizes.
Download
Installation instructions is in the readme.txt file.
Comments
-
On 21.05.08 03:12 GMT Shamus said:
Hi. There is no settings.ini file in the package, as referenced in step 1 of your readme.txt file. Please advise how to access this file. -
On 27.05.08 19:08 GMT Thomas Thomassen said:
My apologies Shamus. The reference to "settings.ini" in the readme.txt is suppose to be "server.ini".
Thanks for pointing that out.
Archived Posts:
Subscribe to this Blog:
Labels:
- accessibility
- animation
- background-image
- barcelona
- career
- changelog
- christmas
- code
- colour
- com
- css
- deardiary
- del
- desktopx
- documentation
- dom
- england
- events
- film
- fun
- gadget
- games
- gestures
- halloween
- html
- ie
- innerhtml
- ins
- javacript
- keyboard
- life
- list-style-image
- lists
- london
- modelmaking
- moving
- msn
- paintball
- php
- pingback
- pixar
- printer
- product
- scanner
- scheme
- scripting
- semantic
- server
- sidebar
- skype
- snow
- software
- split()
- test
- travel
- underground
- userinterface
- vista
- voip
- w3c
- webdesign
- website
- whitespace
