开发者

how to embed WMV files in my html file

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"开发者_JS百科 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.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜