Forum Moderators: phranque

Message Too Old, No Replies

embedded video

         

specter

9:39 pm on Jul 12, 2007 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



hello,

what would be the simplest code to get an embedded video in my web pages?

Thanks

phranque

12:58 am on Jul 13, 2007 (gmt 0)

WebmasterWorld Administrator 10+ Year Member Top Contributors Of The Month



the general answer is to use a set of param tags and an embed tag within an object tag.
the specific answer depends on the media type.

dailypress

2:48 pm on Jul 13, 2007 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



check out youtube and google videos or use a similar code:

<object id="winplayer" classid="clsid:6BF52A52-394A-11d3-B153-00C04F79FAA6" width="425" height="340" type="application/x-oleobject">
<br />
<param name="url" value="http://www.example.com/yourfile.wmv" />
<br />
<param name="autostart" value="true" />
<br />
<param name="uiMode" value="full" />
<br />
<embed src="http://www.example.com/yourfile.wmv" width="425" height="340" autostart="true" uiMode="full" type="application/x-mplayer2" pluginspage="http://www.microsoft.com/Windows/MediaPlayer/"></embed>
<br />
</object>

Hope that helps...

specter

4:54 pm on Jul 13, 2007 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



does that code work also to play the video?

..I uploaded a video to test. I called it directly by url

http://example.com/vid.wmv

but it doesn't play (it prompts to download).

so that code is all I need in order to play an embedded video on my site?

rocknbil

9:01 pm on Jul 14, 2007 (gmt 0)

WebmasterWorld Senior Member 10+ Year Member



http://example.com/vid.wmv

You are calling the video directly, this will always download. You need to call the page the code is in.

Well for S & G's here's the one I use for .wmv.

<object id="mediaplayer1" classid="clsid:22d6f312-b0f6-11d0-94ab-0080c74c7e95"
codebase="http://activex.microsoft.com/activex/controls/mplayer/en/nsmp2inf.cab#Version=5,1,52,701"
standby="Loading Microsoft Windows Media Player components..."
type="application/x-oleobject" width="320" height="300">
<param name="ShowStatusBar" value="1">
<param name="filename" value="http://www.example.com/images/video/file.wmv">
<param name="src" value="http://www.example.com/images/video/file.wmv">
<param name="autostart" value="1">
<param name="volume" value="0">
<embed src="http://www.example.com/images/video/file.wmv"
type="application/x-mplayer2" pluginspage="http://www.microsoft.com/windows/mediaplayer/"
width="320" height="300" autostart="1" volume="0">
</object>

For QuickTime .mov:

<object classid="clsid:02BF25D5-8C17-4B23-BC80-D3488ABDDC6B" width="320" height="300"
codebase="http://www.apple.com/qtactivex/qtplugin.cab#version=6,0,2,0">
<param name="src" value="http://www.example.com/images/video/file.mov">
<embed src="http://www.example.com/images/video/file.mov" width="320" height="300"
pluginspage="http://www.apple.com/quicktime/download/"></embed>
</object>