how to embed WMV files in my html file - html

i have made some demo movies in WMV format that i want to embed in my html page.
I've found some code to do that, but one thing annoys me: it shows a black front in stead of a picture of the first frame.
And i can ofcourse put some descriptive text around the frames/movies, but it isn;t such a nice sight: all black squares with a play button beneath it.
What do i have to do to show a (first) frame of the movie?
This is my code:
classid="CLSID:22D6F312-B0F6-11D0-94AB-0080C74C7E95" standby="Loading Microsoft® Windows® Media Player components..." type="application/x-oleobject" codebase="http://activex.microsoft.com/activex/controls/mplayer/en/nsm p2inf.cab#Version=6,4,7,1112">
<param name="filename" value="http://www.ladieda.com/mymovie.wmv">
<param name="autoStart" value="false">
<param name="showControls" value="true">
<param name="AllowChangeDisplaySize" value="true">
<param name="ClickToPlay" value="true">
<embed type="application/x-mplayer2" pluginspage="http://www.microsoft.com/Windows/MediaPlayer/" SRC="http://www.ladieda.com/mymovie.wmv" AutoStart="false" ></embed>
</object>
Michel
Ps tried it in IE8 and FF3.6, both showed up black.

My example works.
<object id='mediaPlayer' width="320" height="285"
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'>
<param name='fileName' value="http://www.ladieda.com/mymovie.wmv">
<param name='animationatStart' value='true'>
<param name='transparentatStart' value='true'>
<param name='autoStart' value="false">
<param name='showControls' value="true">
<param name='loop' value="true">
<embed type='application/x-mplayer2'
pluginspage='http://microsoft.com/windows/mediaplayer/en/download/'
id='mediaPlayer' name='mediaPlayer' displaysize='4' autosize='-1'
bgcolor='darkblue' showcontrols="true" showtracker='-1'
showdisplay='0' showstatusbar='-1' videoborder3d='-1' width="320" height="285"
src="http://www.ladieda.com/mymovie.wmv" autostart="true" designtimesp='5311' loop="true">
</embed>
</object>
Your example was modified to work:
<object classid="CLSID:22D6F312-B0F6-11D0-94AB-0080C74C7E95" standby="Loading Microsoft® Windows® Media Player components..." type="application/x-oleobject" codebase="http://activex.microsoft.com/activex/controls/mplayer/en/nsm p2inf.cab#Version=6,4,7,1112">
<param name="fileName" value="http://www.ladieda.com/mymovie.wmv">
<param name="autoStart" value="false">
<param name="showControls" value="true">
<param name="AllowChangeDisplaySize" value="true">
<param name="ClickToPlay" value="true">
<embed type="application/x-mplayer2" pluginspage="http://www.microsoft.com/Windows/MediaPlayer/" src="http://www.ladieda.com/mymovie.wmv" autoStart="false" ></embed>
</object>
And yes, it works both on Firefox 3.6 and IE8 (I tested it myself).

<param name="fileName" value="http://www.ladieda.com/mymovie.wmv"> is good for ff
for IE should use name="URL"
too lazy to provide link to msdn.

Related

Prevent embedded HTML video from autoplaying

Here is my code:
<object id="flashObj" width="640" height="390" classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=9,0,47,0">
<param name="movie" value="http://c.brightcove.com/services/viewer/federated_f9?isSlim=0" />
<param name="bgcolor" value="#FFFFFF" />
<param name="flashVars" value="videoId=3945004669001&playerID=2868544859001&playerKey=AQ~~,AAAABvZFMzE~,IXjx0MpOF0rs6Zj6tTY84DVV4TqsG9K-&domain=embed&dynamicStreaming=true" />
<param name="base" value="http://admin.brightcove.com" />
<param name="seamlesstabbing" value="false" />
<param name="allowFullScreen" value="true" />
<param name="swLiveConnect" value="true" />
<param name="allowScriptAccess" value="always" />
<embed src="http://c.brightcove.com/services/viewer/federated_f9?isSlim=1" bgcolor="#FFFFFF" flashVars="videoId=3945004669001&playerID=2868544859001&playerKey=AQ~~,AAAABvZFMzE~,IXjx0MpOF0rs6Zj6tTY84DVV4TqsG9K-&domain=embed&dynamicStreaming=true" base="http://admin.brightcove.com" name="flashObj" width="640" height="390" seamlesstabbing="false" type="application/x-shockwave-flash" allowFullScreen="true" swLiveConnect="true" allowScriptAccess="always" pluginspage=http://www.macromedia.com/shockwave/download/index.cgi?P1_Prod_Version=ShockwaveFlash></embed>
</object>
What code do I need to add, or how can I otherwise prevent this from autoplaying?
You could try something like adding flashvars="play=false"
However whether that will work or not depends on a number of different unknowns.
Check out How to make an embedded video not autoplay The first answer gives a far better explaination of it than I can.
However personally if this were a problem I were facing, assuming there was nothing stopping me from doing it I would use HTML5's video tag convert the desired video to MP4 and use it that way
Check out W3cshools for more info on HTML 5 video http://www.w3schools.com/html/html5_video.asp
I hope that helps !

Firefox 21+ won't read video objects from mms protocol

I have a website that delivers content from an mms:// protocol, but latest Firefox version seem to ignore the video object. Is it possible to force Firefox to read/load files from an mms:// protocol?
HTML5
<object classid="CLSID:22D6F312-B0F6-11D0-94AB-0080C74C7E95" width="870" height="550" codebase="http://www.microsoft.com/Windows/MediaPlayer/ object">
<param name="Filename" value="mms://24.212.0.21/archives/tvc9/CC_A2013_01.wmv">
<param name="AutoStart" value="true">
<param name="ShowControls" value="true">
<param name="BufferingTime" value="true">
<param name="ShowStatusBar" value="true">
<param name="AutoSize" value="true">
<param name="InvokeURLs" value="true">
<embed src="mms://24.212.0.21/archives/tvc9/CC_A2013_01.wmv" type="video/x-ms-wmv" autostart="true" bufferingtime="2" showcontrols="true" showstatusbar="true" autosize="true" pluginspage="http://www.microsoft.com/Windows/MediaPlayer/" codebase="http://activex.microsoft.com/activex/controls/mplayer/en/nsmp2inf.cab#Version=6,0,0,0" width="870" height="550">
</object>
It works in all other browsers. I cannot change the source server.
JSFiddle

Play midi files using chrome

I am using embed player for playing midi files.
It is playing in mozilla and in explorer how can i play that midi files in chrome, is there any extension or plugin by which i can play midi in chrome.
here is my code
<object
id="MediaPlayer" width="300" height="300"
classid="CLSID:6BF52A52-394A-11D3-B153-00C04F79FAA6"
standby="Loading Microsoft Windows Media Player components..."
type="application/x-oleobject">
<param name="Url" value="suite1.mid">
<param name="AutoSize" value="true">
<param name="AutoStart" value="true">
<param name="Balance" value="0">
<param name="DisplaySize" value="0">
<param name="Mute" value="false">
<param name="PlayCount" value="0">
<param name="Rate" value="1.0">
<param name="ShowAudioControls" value="true">
<param name="ShowControls" value="true">
<param name="ShowDisplay" value="true">
<param name="ShowStatusBar" value="true">
<param name="ShowTracker" value="true">
<param name="StretchToFit" value="false">
<param name="TransparentAtStart" value="false">
<param name="Volume" value="100">
<embed type="application/x-mplayer2"
name="mediaplayer"
pluginspage="http://www.microsoft.com/Windows/MediaPlayer"
src="suite1.mid"
Height="300"
Width="300"
AutoSize="1"
AutoStart="1"
Balance="0"
DisplaySize="0"
Mute="0"
PlayCount="0"
Rate="1.0"
ShowAudioControls="1"
ShowControls="1"
ShowDisplay="1"
ShowStatusBar="1"
ShowTracker="1"
StretchToFit="0"
TransparentAtStart="0">
Volume="100"
</embed>
</object>
It is working on mozilla and explorer.
Windows Media Player will probably not work with Chrome, and will not anyway work for every user. Look at HTML5 (e.g. http://mudcu.be/midi-js/, sources on https://github.com/mudcube/MIDI.js) or Flash (e.g. http://code.google.com/p/flash-midi-player/) MIDI players instead.

HTML Object Embed sound volume

I don't know why, but the VOLUME attr is not working. It can be 0 or 100 I can't hear any difference.
<object>
<param name="autostart" value="true">
<param name="src" value="scream14.wav">
<param name="autoplay" value="true">
<param name="controller" value="true">
<embed src="scream14.wav" volume="0" hidden="true" controller="true" autoplay="true" autostart="true" type="audio/wav" loop="false"/>
</object>
I tested the code and it was running correctly

wmode=transparent lightens the gray color in swf

I am using lightbox++ to load images outside of flash in order to make that work I have to set
wmode=transparent
in the object properties
But doing this lightens the gray color used in the swf..
Without adding wmode=transparent
Screenshot with wmode=transparent
Can anybody explain this behavior?
here is the whole code
<object classid="clsid:D27CDB6E-AE6D-11cf-96B8-444553540000" style="display: block" codebase="http://download.macromedia.com/pub/shockwave/cabs/flash/swflash.cab#version=7,0,19,0" width="100%" height="100%;">
<param name="movie" value="site.swf">
<param name="quality" value="high">
<param name="menu" value="false">
<param name="allowscriptaccess" value="always" />
<param name="wmode" value="transparent" />
<param name="allowFullScreen" value="true">
<embed src="site.swf" allowfullscreen="true" wmode="transparent" menu="false" quality="high" pluginspage="http://www.macromedia.com/go/getflashplayer" type="application/x-shockwave-flash" width="100%" height="100%">
Ok I found a hint to the solution on this page
this is what i had done to fix the issue
wmode="opaque"
(by default the swf is set to be on top of all thus we have to use wmode to decide how we want to diplay the swf)
http://kb2.adobe.com/cps/127/tn_12701.html