...

View Full Version : Full screen Media Player in FireFox



shakil_s
06-20-2006, 01:50 PM
Hi,

I am having major problems with getting a media player object go into full screen mode in FireFox. It works fine with IE, but not with FireFox. The video loads up fine in FireFox, and when the video starts I can right-click in the player and zoom to full -screen, but why can't I get it to go full screen using the hyperlink.

I want to use a link only to get the player into full screen, but for some reason FireFox doesnt do a thing. I think it might be to do with javascript.

Here is the code I am using.

Thanks.

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


<html>
<head>
</head>
<body>

<form id="form1">
<div id="video">
<OBJECT id="MediaPlayer1" name="MediaPlayer1" width="232" height="180"

classid="CLSID:6BF52A52-394A-11d3-B153-00C04F79FAA6" VIEWASTEXT>
<PARAM NAME="URL" VALUE="http://members.aol.com/jrzycrim01/mozilla/wmp/wmptest_ax.wmv">
<PARAM NAME="rate" VALUE="1">
<PARAM NAME="balance" VALUE="0">
<PARAM NAME="currentPosition" VALUE="0">
<PARAM NAME="defaultFrame" VALUE="">
<PARAM NAME="playCount" VALUE="1">
<PARAM NAME="autoStart" VALUE="-1">
<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="0">
<PARAM NAME="windowlessVideo" VALUE="0">
<PARAM NAME="enabled" VALUE="-1">
<PARAM NAME="enableContextMenu" VALUE="-1">
<PARAM NAME="fullScreen" VALUE="false">
<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="7726">
<PARAM NAME="_cy" VALUE="5292">
<embed TYPE="application/x-mplayer2"

pluginspage="http://www.microsoft.com/isapi/redir.dll?prd=windows&sbp=mediaplayer&ar=Media&sba=Plugin&" SRC="http://members.aol.com/jrzycrim01/mozilla/wmp/wmptest_ax.wmv" Name="MediaPlayer1" ShowControls="1" Width="232" Height="205">
</Embed>
</OBJECT>

</div>
</div>

<div class="breakleft">
<a href="#" onclick="PlayFullScreen()">Full Screen Mode</a></div>
<div class="breakright">
<A HREF="http://www.microsoft.com/windows/windowsmedia/player/download/"><IMG ALT="Get Windows Media Player"SRC="http://www.microsoft.com/windows/windowsmedia/images/logos/wmp10/Download_88x31_static.gif" WIDTH="88" HEIGHT="31" BORDER="0"></A>
</div>
</form>


<script language="javascript">
function PlayFullScreen()
{
//document.form1.MediaPlayer1.fullScreen = "true";
var d = document.getElementById("form1");
d.MediaPlayer1.setAttribute("fullScreen", "true");
}
</script>


</body>
</html>

kaitco
06-20-2006, 01:57 PM
Add this

width="100%" height="100%"
to your object tag.

shakil_s
06-20-2006, 02:05 PM
That just changes the size though initially. If you run the code I posted above, in IE, you can click the link and the media player will open as full-screen. That is exactly what I want, but it's not working in Firefox.

If I set the <PARAM NAME="fullScreen" VALUE="false"> value to "true" then again, IE automatically loads it as full-screen, but Firefox just plays it in small size.

_Aerospace_Eng_
06-20-2006, 04:07 PM
The fullscreen method requires activex to be installed on Firefox. Since it isn't the fullscreen method won't work. IE has activex installed which is why it works.

shakil_s
06-20-2006, 04:24 PM
Ah, OK. Thanks _Aerospace_Eng_ .



EZ Archive Ads Plugin for vBulletin Copyright 2006 Computer Help Forum