Stream video file?

I need to transfer the FLV file. Streaming should look like streaming, and I should have a way to change the destination file.
Sorry for my poor English.

+2
source share
2 answers

If “streaming” means “showing a flash video”, flv-streaming is not really streaming, but the usual file transfer when the player starts playing, even if the file is not fully downloaded for the client. Time search is implemented in the standard HTTP method with file upload offset - if you scroll the video halfway on the timeline and it is not already loaded, the current download (most often) is interrupted and restarts with a file offset of / 2 bytes.

So, you can be fine just using the plain old one readfile()and setting the HTTP type header headers appropriately header(). But, since you need to search, you need to parse the HTTP request, and instead readfile()use it fpassthru(), searching in the right place.

tl; dr. PHP Apache ( httpd ) .

+4

, , - Youtube-esque -, Flowplayer - API Javascript, , , , .

.

0

All Articles