john-formby
asked on
Detect Media Player Version and Use
Hi,
I have just updated a media player object and made it cross browser compatible for a friends website, but she has now said that it will not work with earlier versions of media player. Is there a way of adapting the following code to make it detect the version of media player installed and use that? It needs to work for IE, Netscape, Mozilla Firefox etc. The version she said she had tried and had trouble with is media player 6.1.
Here is the code for the media player:
<td class="mplayerCell">
<object id="Player" classid="CLSID:22d6f312-b0 f6-11d0-94 ab-0080c74 c7e95"
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-oleobj ect" width="320" height="320">
<param name="ShowStatusBar" value="true">
<param name="autostart" value="true">
<param name="ShowAudioControls" value="false">
<param name="ShowDisplay" value="false">
<param name="ShowGotoBar" value="false">
<param name="ShowTracker" value="false">
<param name="ShowPositionControls " value="false">
<param name="CaptioningID" value="capText">
<div id=mediaPlayerMozilla>
<embed type="application/x-mplaye r2" pluginspage="http://microsoft.com/windows/mediaplayer/en/download/" showControls="1" width="320" height="320"></embed>
<div>
</object>
</td>
Thanks in advance,
John
I have just updated a media player object and made it cross browser compatible for a friends website, but she has now said that it will not work with earlier versions of media player. Is there a way of adapting the following code to make it detect the version of media player installed and use that? It needs to work for IE, Netscape, Mozilla Firefox etc. The version she said she had tried and had trouble with is media player 6.1.
Here is the code for the media player:
<td class="mplayerCell">
<object id="Player" classid="CLSID:22d6f312-b0
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-oleobj
<param name="ShowStatusBar" value="true">
<param name="autostart" value="true">
<param name="ShowAudioControls" value="false">
<param name="ShowDisplay" value="false">
<param name="ShowGotoBar" value="false">
<param name="ShowTracker" value="false">
<param name="ShowPositionControls
<param name="CaptioningID" value="capText">
<div id=mediaPlayerMozilla>
<embed type="application/x-mplaye
<div>
</object>
</td>
Thanks in advance,
John
ASKER CERTIFIED SOLUTION
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
in that script u have this
if(is_WMP71up)
this wud return true if the windows media player version is greater than 7
now if its not windows media player 7 and above what does ur code needs to do?>
if(is_WMP71up)
this wud return true if the windows media player version is greater than 7
now if its not windows media player 7 and above what does ur code needs to do?>
ASKER
Is there anyway of getting it to work with version 6.1 of media player? If not, or the user is using an earlier version, it needs to display a message and link saying that they need to upgrade the current version. Is this possible?
John
John
ASKER
<script type="text/javascript" src="sniffer2.js"></script
in the head section of the page and it will automatically detect which version of the media player to load when the page is loaded? I don't need to change any of the code I posted above?
Thanks,
John