You are here: Re: fpassthru and mp3 player « PHP Programming Language « IT news, forums, messages
Re: fpassthru and mp3 player

Posted by Andy Hassall on 10/23/28 11:26

On Mon, 12 Sep 2005 12:46:06 +0200, alex bazan <me@privacy.net> wrote:

>En/na Andy Hassall ha escrit:
>> On Mon, 12 Sep 2005 11:05:39 +0200, alex bazan <me@privacy.net> wrote:
>>
>>>If i point the mp3 directly i have no problems, but with the php script
>>>songs stop playing when after a while (always at the same length)...
>>
>>
>> How is the player reading the file?
>>
>> If it is streaming it, i.e. only reading just about as fast as it's playing
>> give or take a buffer size, it'll exceed PHP's maximum execution time, and PHP
>> will drop the connection.
>
>Yes, it's streaming... when i read that i said, bingo!
>but i've raised the max_execution_time to 300s in php.ini and also with
>the ini_set function, and i've also tried raising it with
>set_time_limit(), but the song always stops at the same point at 1:25
>(aprox).... (thats less than 90 seconds!)

OK, so you need to find a way of reproducing that behaviour in a way where you
can see what's happening right at the end.

Turn on log_errors in PHP in case it's producing a PHP error at the end - you
can't see the error text since the player will be receiving it, but if you turn
on log_errors it'll also log it to a file so you can check for it.

You could use something like Ethereal to packet-sniff the transfer, paying
more attention to the last few packets.

--
Andy Hassall :: andy@andyh.co.uk :: http://www.andyh.co.uk
http://www.andyhsoftware.co.uk/space :: disk and FTP usage analysis tool

 

Navigation:

[Reply to this message]


Удаленная работа для программистов  •  Как заработать на Google AdSense  •  England, UK  •  статьи на английском  •  PHP MySQL CMS Apache Oscommerce  •  Online Business Knowledge Base  •  DVD MP3 AVI MP4 players codecs conversion help
Home  •  Search  •  Site Map  •  Set as Homepage  •  Add to Favourites

Copyright © 2005-2006 Powered by Custom PHP Programming

Сайт изготовлен в Студии Валентина Петручека
изготовление и поддержка веб-сайтов, разработка программного обеспечения, поисковая оптимизация