|Welcome to the Monastery|
Perl vs. PHP in streaming a fileby krkeegan (Novice)
|on Nov 24, 2004 at 17:42 UTC||Need Help??|
krkeegan has asked for the wisdom of the Perl Monks concerning the following question:
I have been tinkering with using perl or php to serve files to my TIVO.
When I use perl the streamed music file skips badly, and no matter how I alter the amount read before it prints I still get really bad skipping. But if I use explorer to download the same file thru the script I get hugh kbps. Here is a portion of my script:
This is a file that was opened with IO:File
So I went and tried a php version that some else had created and it worked perfectly. The php version used fopen and fpassthru.
My question is, I don't think this is a speed problem with perl since I can download the file thru the script superfast. But WHY IS PHP WORKING SO MUCH BETTER AT THIS TASK? And is there a better perl method to read and send the file?
Thanks for your help,