25 tháng 1, 2008

Embedding Windows Media Player


To embed an object in HTML document, the object class ID is required. The class ID for Windows Media Player 7, 9, 10 and 11 is clsid:6BF52A52-394A-11D3-B153-00C04F79FAA6.

Insert the following code into your HTML document to embed Windows Media Player 7 and later:

&lt OBJECT id="VIDEO" width="320" height="240"
style="position:absolute; left:0;top:0;"
CLASSID="CLSID:6BF52A52-394A-11d3-B153-00C04F79FAA6"
type="application/x-oleobject">

&lt PARAM NAME="URL" VALUE="your file or url">
&lt PARAM NAME="SendPlayStateChangeEvents" VALUE="True">
&lt PARAM NAME="AutoStart" VALUE="True">
&lt PARAM name="uiMode" value="none">
&lt PARAM name="PlayCount" value="9999">
&lt /OBJECT>
Most important parameters supported by Windows Media Player 7 and later:

Parameter Default Description
autoStart true Specifies or retrieves a value indicating whether the current media item begins playing automatically.
balance 0 Specifies the current stereo balance.
Values range from –100 to 100.
baseURL
Specifies the base URL used for relative path resolution with URL script commands that are embedded in media items.
captioningID 0 Specifies the name of the element displaying the captioning.
currentMarker 0 Specifies the current marker number.
currentPosition 0 Specifies the current position in the media item in seconds.
defaultFrame - Specifies the name of the frame used to display a URL.
enableContextMenu true Specifies a value indicating whether to enable the context menu, which appears when the right mouse button is clicked.
enabled false Specifies whether the Windows Media Player control is enabled.
fullScreen false Specifies whether video content is played back in full-screen mode.
InvokeURLs true Specifies a value indicating whether URL events should launch a Web browser.
Mute false Specifies if audio is muted.
PlayCount 1 Specifies the number of times a media item will play. Minimum value of one.
Rate 1.0 Specifies the playback rate.
0.5 equates to half the normal playback speed, 2 equates to twice.
stretchToFit false Specifies whether video displayed by the control automatically sizes to fit the video window, when the video window is larger than the dimensions of the video image.
uiMode full Specifies which controls are shown in the user interface.
Possible values: invisible, none, mini, full.
URL - Specifies the name of the media item to play.
You can specify a local filename or a URL.
Volume Last setting Zero specifies no volume and 100 specifies full volume.
windowlessVideo false Specifies or retrieves a value indicating whether the Windows Media Player control renders video in windowless mode.
When windowlessVideo is set to true, the Player control renders video directly in the client area, so you can apply special effects or layer the video with text.
Supported by Windows Media Player for Windows XP or later.


If you want to embed Windows Media Player 6.4 instead of the latest version, the class ID is clsid:22D6F312-B0F6-11D0-94AB-0080C74C7E95.
-->đọc tiếp...
BlogWeb: tạo từ Blog của Google
Nội dung: lấy từ nhiều Nguồn khác nhau.
Mục đích: note lại bài Hướng dẫn hay và Đáng đọc.
Kết quả: nghiện Internet Nặng.
Tương lại: xuống lỗ Vẫn Nghiện nếu không có ai giúp.
Blog Web của: Trí Dũng đến từ Việt Nam - Liên kết đến trang Blog Cá Nhân
Tôi biết (^_^)
Thông tin về Tác giả. Chi Tiết
Sử dụng (FireFox | Google Chrome on Ubuntu) để xem tốt nhất. Học Nhiều Hơn Tại Đây
©2009 Google Blogger - HuuNguyen's Home