PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!
i've got a video file that I have on my website that i'd like to allow only certain people to see. To accomplish this i've setup a system that uses one-time use urls so that I can link people to the page but then in turn they can't spread the link around. I was planning on using readfile() to display the .avi file while keeping the location secret but nothing is displayed when I do this. At first I thought it might be because of the size of the video is greater than memory_limit but I figure i'd get an error message if that was true.
Any ideas on alternative functions or method of accomplishing the same thing?
the "header" in an .avi comes at the end of the file, therefore, the user must download the entire file before they can determine how to process it. If it were converted to a streaming media, such as WMV or QuickTime, it would start playing relatively quickly, provided the download speed is decent.
Is the problem this that readfile is not returning anything or the file not playing? Are the right headers sent before you output the content (if any comes past readfile) ?