Thứ Bảy, 12 tháng 3, 2011

Chèn Windows Media Player vào blog

Cách này sử dụng rất tốt trên Google Blogger cũng như các blog hỗ trợ tốt HTML khác .

1 . Code dùng để chèn Video
<embed pluginspage="http://www.microsoft.com/Windows/Downloads/Contents/Products/Med&#13;&#13;&#10;iaPlayer/" src="Link đến file video" width="320" height="285" type="application/x-mplayer2" showstatusbar="1" showdisplay="false" AutoStart="0" ClickToPlay="1" showcontrols="1" playcount="10" enablecontextmenu="false" enabled="-1" windowlessvideo="0" stretchtofit="0" uimode="full" mute="0" volume="100" currentmarker="0" loop="true" fullscreen="0" controls="controlpanel" />


2 . Code dùng để chèn Audio






<OBJECT id=winMediaPlayerID codeBase=http://activex.microsoft.com/activex/controls/mplayer/en/nsmp2inf.cab#Version=6,4,5,715 type=application/x-oleobject height=45 standby="Loading Microsoft Windows Media Player components..." width=250 classid=CLSID:6BF52A52-394A-11D3-B153-00C04F79FAA6 name=winMediaPlayer><PARAM NAME="URL" VALUE="LINK ĐẾN FILE AUDIO"><PARAM NAME="rate" VALUE="1"><PARAM NAME="balance" VALUE="0"><PARAM NAME="currentPosition" VALUE="0"><PARAM NAME="defaultFrame" VALUE="0"><PARAM NAME="playCount" VALUE="999"><PARAM NAME="autoStart" VALUE="0"><PARAM NAME="currentMarker" VALUE="0"><PARAM NAME="invokeURLs" VALUE="-1"><PARAM NAME="baseURL" VALUE=""><PARAM NAME="volume" VALUE="50"><PARAM NAME="mute" VALUE="0"><PARAM NAME="uiMode" VALUE="full"><PARAM NAME="stretchToFit" VALUE="-1"><PARAM NAME="windowlessVideo" VALUE="0"><PARAM NAME="enabled" VALUE="-1"><PARAM NAME="enableContextMenu" VALUE="0"><PARAM NAME="fullScreen" VALUE="0"><PARAM NAME="SAMIStyle" VALUE=""><PARAM NAME="SAMILang" VALUE=""><PARAM NAME="SAMIFilename" VALUE=""><PARAM NAME="captioningID" VALUE=""><PARAM NAME="enableErrorDialogs" VALUE="0"><PARAM NAME="_cx" VALUE="6615"><PARAM NAME="_cy" VALUE="1191">
<EMBED type="application/x-mplayer2" id="wmpEmbed" pluginspage="http://www.microsoft.com/Windows/MediaPlayer/" src="LINK ĐẾN FILE AUDIO" name="MediaPlayerTV" height="45" width="250" AutoSize="1" AutoStart="0" ClickToPlay="1" DisplaySize="1" EnableContextMenu="0" EnableFullScreenControls="1" EnableTracker="1" Mute="0" PlayCount="999" ShowControls="1" ShowAudioControls="1" ShowDisplay="0" ShowGotoBar="0" ShowPositionControls="1" ShowStatusBar="1" ShowTracker="1">
</EMBED></OBJECT>


Nếu bạn chọn AutoStart ="1" thì chương trình sẽ tự động chơi Video . Rất mong được nhận ý kiến từ các bạn

0 nhận xét: