Studio64
10-30-2002, 09:23 AM
OK... Kinda an in depth PHP question I want opinions on. I'll try to explain it as best as possible.
The Location function can send out the headers for the page. It's simple to display an image through it by setting the content type to jpeg/gif whatever...
Now PHP can do this very well because image files are small comparably... I want to do this with video files (essentially to stop bandwidth leeching)..
Essentially the script will verify that the HTTP_REFERER is correct the send the header in the form of content mpeg or whatever.
Now the problems. Video files can be large (max on the site will be around 40 megs) so when you do the include after sending the header PHP (your server) must load that entire file into memory in order to parse the page?
True? (Would this be a memory hog. Think multiple connections to a 30 meg file)
Any suggestions/comments/apparent problems?
The Location function can send out the headers for the page. It's simple to display an image through it by setting the content type to jpeg/gif whatever...
Now PHP can do this very well because image files are small comparably... I want to do this with video files (essentially to stop bandwidth leeching)..
Essentially the script will verify that the HTTP_REFERER is correct the send the header in the form of content mpeg or whatever.
Now the problems. Video files can be large (max on the site will be around 40 megs) so when you do the include after sending the header PHP (your server) must load that entire file into memory in order to parse the page?
True? (Would this be a memory hog. Think multiple connections to a 30 meg file)
Any suggestions/comments/apparent problems?
