On Sep 17, 10:53*pm, "Oscar Arreyano" <anot...@example.comwrote:
I did a website for a friend's company where they wanted a 'downloads'
section similar to standard file sharing you see all over the place.
Everything works great except for video. I know there are codecs involved,
however, if i create a video (I've tried mpg, avi, wma so far) I can watch
it on my pc from disk just fine. Since my pc is also my test environment,I
try to open the same video from the test site and I get the standard 'Can't
do it...Close...Web Help' response. I would assume that I need to be
supplying codec info along with the video on the web side of things? I
assume this since I know I *have* the correct codec on my pc to begin with.
I know it's not a directly php related subject, but there is good traffic
here including the default response I know most will give...'This is a PHP
news group...go ask in x ng'.
All help is appreciated. Video over the web is completely new to me.
Although most video formats can be served without the use of any php,
there are other cases when writing most of the code in php helps a
lot. For example, I am now offering the choice of 4 video formats on
some pages. One selects the format desired by clicking on an image
map. A php form sends the choice to the server which then writes the
video code for just the video format selected and not the 3 formats
not used. This is downloaded to the browser and saves the download of
much code for other formats that is not needed for the choice of video
format made. See my page at
http://www.cwdjr.net/video4/cancan.php .
If this high broadband page is too fast to start streaming soon, try
http://www.cwdjr.net/video4/cancanL.php for the low broadband version.
See the php text file at
http://www.cwdjr.net/video4/cancan.txt .
If you are allowed only one video format, I would choose flv/swf
flash. If Adobe is to be believed, flash is installed on about 99% of
computers in developed nations in N America and Europe. Many major
news sites, YouTube, US government departments, etc now use only this
video format, and many of these sites have converted to flash from
Microsoft and Real formats. Since introduction of the flv(flash video)
a few versions back, flash is now capable of everything from very high
resolution movies to very low resolution ads. If you are interested in
only videos, a flash flv/swf encoder can be had for around US$50. Of
course the full official flash suite is quite expensive. The flash
encoder takes an input such as a high resolution mpg that is far too
large in size for the web. You can select many conditions for the
video and audio. Also you can build the player in many ways. The
program outputs both a .flv video file and .swf container file, both
of which must be uploaded into the same directory on the server. The
page code only calls for the .swf file. However the swf container file
internally signals the start of download of the .flv file to the
browser temporary cache and streaming starts very soon if the download
connection is fast enough.
There are many programs for encoding in Microsoft and Real formats,
and both companies still offer a free encoder for their formats. Also
many programs will encode QT mov videos. However to stream, QT movies
must be hinted, and this usually is not done on many QT encoders. The
most simple way to do is open a QT video in the pro pay version of the
QT player and then store it somewhere. The stored .mov video will be
hinted for progressive download streaming.
Video is one of the more complicated things you can do if you wish to
embed the video on an html page and have it work on most popular
browsers. If you are content to just bring up a full player, such as
the WMP, that may obscure much are all of the page, much more simple
code often will work.