页面嵌入Windows Media Player播放器代码需要注意的

时间:2023-07-02 17:04:48 

这里是WMP的版本ClassID,从WMP7后ID就成了clsid:6BF52A52-394A-11D3-B153-00C04F79FAA6,之前的6.4为clsid:22D6F312-B0F6-11D0-94AB-0080C74C7E95,但是之前的版本还是可以用的,只不过新功能用不了罢了。

下面这个是具体的版本号,你可以对比一下你现在的是什么版本。

版本号              Windows Media Player (WMP) 的版本
----------------------------------------------------------------
5.1.51.421       WMP 5.2 Beta
5.1.52.701       WMP 5.2
6.02.902         WMP 6.0
6.1.5.130        WMP 6.0 Internet Explorer 5 RC0 Beta
6.1.7.217        WMP 6.0
6.2.5.410        WMP 6.2 Beta
6.4.5.809        WMP 6.4
6.4.6.*           WMP 6.4 for Windows 2000 Beta
6.4.7.1028         WMP 6.4,具有多位速率 (MBR) 更新,用于Internet Explorer
6.4.7.1112       WMP 6.4,具有 MBR 更新(在 6.4.7.1028 的基础上对错误消息进行了较小更新)
6.4.9.*            WMP 6.4,仅用于 Windows 2000
7.0.0.1954       WMP 7
7.0.0.1958       WMP 7 更新
7.0.0.1956       WMP 7,更新了安装程序
7.0.0.1440       WMP 7,用于 Windows Millennium Edition (Me)
7.01.00.3055      WMP 7.1
8.00.00.4477      WMP for Windows XP
9.00.00.2980     WMP 9 系列,用于 Windows XP、Windows 98 Second Edition、Windows Me 和 Windows 2000
9.00.00.2991        WMP 9 系列,用于 Windows Server 2003
10.00.00.3646    WMP 10

---------------------------------------------------------------------------------------------------------------

官方的插入方式真够简单的,我都有点想踹他们两脚,

<OBJECT ID="Player"
  CLASSID="CLSID:6BF52A52-394A-11d3-B153-00C04F79FAA6">
    <PARAM name="autoStart" value="True">
</OBJECT>
下面是具体参数在不同浏览器的可用性,这个东东真是太有用了,好多参数用了不起作用,我都测试的快疯了,一看这个列表,原来人家压根不支持,晕...

PARAM nameInternet ExplorerFirefox with mime type application/x-ms-wmpFirefox with any other mime type
autoStartyesyesyes
balanceyesyesyes
baseURLyesyesyes
captioningIDyesyesyes
currentMarkeryesyesyes
currentPositionyesyesyes
defaultFrameyesnono
enableContextMenuyesyesyes
enabledyesyesyes
enableErrorDialogsyesyesno
fileNamenoyesyes
fullScreenyesnono
invokeURLsyesnono
muteyesyesyes
playCountyesyesno
rateyesyesyes
SAMIFileNameyesyesyes
SAMILangyesyesyes
SAMIStyleyesyesyes
SRCnoyesyes
stretchToFityesyesno
URLyesyesyes
volumeyesyesyes
windowlessVideoyesyesyes

 参数的默认值:

ParameterDefaultDescription
AudioStreamtrue 
AutoSizetrue 
AutoStarttrueSets if the player should start automatically
AnimationAtStarttrueSets if an animation should show while the file loads
AllowScantrue 
AllowChangeDisplaySizetrue 
AutoRewindfalse 
Balancefalse 
BaseURL  
BufferingTime5 
CaptioningID  
ClickToPlaytrueSets if the player should start when the user clicks in the play area
CursorTypefalse 
CurrentPositiontrue 
CurrentMarkerfalse 
DefaultFrame  
DisplayBackColorfalse 
DisplayForeColor16777215 
DisplayModefalse 
DisplaySizefalse 
Enabledtrue 
EnableContextMenutrue 
EnablePositionControlstrue 
EnableFullScreenControlsfalse 
EnableTrackertrue 
FilenameURLThe URL of the file to play
InvokeURLstrue 
Languagetrue 
Mutefalse 
PlayCount1 
PreviewModefalse 
Rate1 
SAMILang  
SAMIStyle  
SAMIFileName  
SelectionStarttrue 
SelectionEndtrue 
SendOpenStateChangeEventstrue 
SendWarningEventstrue 
SendErrorEventstrue 
SendKeyboardEventsfalse 
SendMouseClickEventsfalse 
SendMouseMoveEventsfalse 
SendPlayStateChangeEventstrue 
ShowCaptioningfalse 
ShowControlstrueSets if the player controls should show
ShowAudioControlstrueSets if the audio controls should show
ShowDisplayfalseSets if the display should show
ShowGotoBarfalseSets if the GotoBar should show
ShowPositionControlstrue 
ShowStatusBarfalse 
ShowTrackertrue 
TransparantAtStartfalse 
VideoBorderWidthfalse 
VideoBorderColorfalse 
VideoBorder3Dfalse 
Volume-200 
WindowlessVideofalse 

 可能你最想知道的是怎么用程序(我偏向用JS)来控制WMP的播放、停止、快进吧,看看这里吧,http://msdn.microsoft.com/en-us/library/dd564034%28VS.85%29.aspx,有详细的说明和例子。(英文的)

标签:Media,Player,播放器代码
0
投稿

猜你喜欢

  • python获取服务器响应cookie的实例

    2023-06-14 15:02:50
  • window下mysql 8.0.15 winx64安装配置方法图文教程

    2024-01-23 10:58:58
  • mysql中general_log日志知识点介绍

    2024-01-12 23:49:58
  • python 可视化库PyG2Plot的使用

    2022-10-14 05:22:17
  • JS完美实现对象克隆

    2008-08-03 16:51:00
  • python 自动去除空行的实例

    2021-04-12 08:46:04
  • python妹子图简单爬虫实例

    2022-12-11 05:47:50
  • 使用Python项目生成所有依赖包的清单方式

    2022-02-18 19:14:49
  • Python+OpenCV图像处理——图像二值化的实现

    2021-05-15 04:39:03
  • Python数据可视化之简单折线图的绘制

    2021-05-25 11:59:30
  • Golang Gob编码(gob包的使用详解)

    2024-02-22 02:16:46
  • sql 存储过程批量删除数据的语句

    2024-01-21 17:40:23
  • Python 文件处理之open()函数

    2021-03-04 02:26:49
  • python实现单例的两种方法解读

    2022-04-10 21:10:46
  • Python 多个图同时在不同窗口显示的实现方法

    2022-07-02 01:20:35
  • javascript实现炫酷的拖动分页

    2024-06-19 01:46:04
  • vue项目中常见问题及解决方案(推荐)

    2024-04-26 17:37:47
  • 使用mysql_udf与curl库完成http_post通信模块示例

    2024-01-21 15:56:04
  • python渗透测试linux密码激活的示例

    2023-06-25 16:57:41
  • Python3中的f-Strings增强版字符串格式化方法

    2022-07-07 12:34:36
  • asp之家 网络编程 m.aspxhome.com