Topic: Custom controls for windows media player Full Screen button (Page 1 of 1) Pages that link to <a href="https://ozoneasylum.com/backlink?for=25041" title="Pages that link to Topic: Custom controls for windows media player Full Screen button (Page 1 of 1)" rel="nofollow" >Topic: Custom controls for windows media player Full Screen button <span class="small">(Page 1 of 1)</span>\

 
aponex
Neurotic (0) Inmate
Newly admitted

From:
Insane since: Feb 2005

posted posted 02-17-2005 18:22

HELP! I?ve been working on this for a while now. I?ve been trying everything I know to get this full screen button to work. The javascript code I?ve been using is as follows:

function fullScreen() {
player=document.getElementById("Player");
if player.DisplaySize==3) {
player.fullScreen=true;
}
}
and I?ve also tried:

function fullScreen()
{
Player.DisplaySize=3;
}

now I?m not a real java guru obviously cuz I can?t get these to work but this is a result of research that I?ve done over the net. The object ID for the media player is simply "Player" Then I use this button for activating this function:

<a href="javascript:fullScreen();"><IMG SRC="images1.jpg" ALT="" width="125" height="125" border="0"></a>

I?m also going to need to alter the up and down volume and other broadcast system. Any help will be greatly appreciated!! Thanks

-APONE-

(Edited by aponex on 02-17-2005 18:24)

(Edited by aponex on 02-17-2005 18:27)

Tyberius Prime
Paranoid (IV) Mad Scientist with Finglongers

From: Germany
Insane since: Sep 2001

posted posted 02-17-2005 22:43

Knowing just about nothing about controling mediaplayer via javascript,
I still suppose your fullscreen function should be actual valid javascript...

code:
function fullScreen() 
{
var player=document.getElementById("Player"); //don't forget the var. It will come and bite you.
if (player.DisplaySize==3) //you were missing the (. 3 you should probably check for playState, where 3 means 'playing'
{
player.fullScreen=true;
}
}
or
function fullScreen()
{
var player=document.getElementById("Player");
player.DisplaySize=3;
}



I suppose only one of these actual set's your player into fullscreen, and google groups suggest it's the first one.

So long,

->Tyberius Prime

aponex
Obsessive-Compulsive (I) Inmate

From:
Insane since: Feb 2005

posted posted 02-18-2005 00:02

Tyberius Prime

Both the codes you posted worked. Thank you so much YOU ROCK!

-APONE-

borrow
Obsessive-Compulsive (I) Inmate

From: Australian living in UK
Insane since: Jul 2005

posted posted 07-04-2005 01:08

Hey Tyberius Prime!

Just read your program and comments for Apone.

I have similar but complicated problem here to do with 'fullScreen' for Windows Media Player (WMP).

I use JavaScript file for inserting and setting the video clip for most browsers to work - you can check the JavaScript file:
http://lyndonborrow.com/sample/video_setting.js

And on the HTML page I have...

code:
<html>
<head>
<title>Test</title>
<script src="/sample/video_setting.js" type="text/javascript"></script>
</head>

<body>

<div id="iVideo">
  <script type="text/javascript">fWriteWMV("solvideo", 320, 308, "http://www.sample.org.uk/videos/homepage2-3.wmv")</script>
</div>

</body>
</html>




Now, on the HTML page, I tried to add button on below the WMP for 'Full Screen' view with these...

code:
<a href="javascript:fullScreen();"><IMG SRC="button.jpg" ALT="" width="80" height="80" border="0"></a>




It didn't work???? I tried with alternations, but none worked...... AAARRGGG!!!

Do you know if there's a way to fix, please?


LYNDON BORROW

bucabay
Neurotic (0) Inmate
Newly admitted

From:
Insane since: Jul 2005

posted posted 07-19-2005 00:18

Hi,

With my very limited javascript knowledge.... not to mention wmplayer's javascript api

In http://lyndonborrow.com/sample/video_setting.js
I believe you should change

code:
function fullScreen()
{
	var player=document.getElementById("solvideo");
	if (solvideo.DisplaySize==3)
	{
		solvideo.fullScreen=true;
	}
}



to

code:
function fullScreen()
{
	var player=document.getElementById("solvideo");
	if (player.DisplaySize==3) // player is the wmplayer object not solvideo
	{
		player.fullScreen=true;
	}
}



You could also do this:

code:
function fullScreen(id)
{
	var player=document.getElementById(id); // id is dynamic
	if (player.playState == 3) // check wmplayer status
	{
		player.fullScreen=true;
	}
}



This way you could use the function for different wmplayer objects.

(Edited by bucabay on 07-19-2005 00:23)

DRAKULA
Neurotic (0) Inmate
Newly admitted

From:
Insane since: Dec 2005

posted posted 12-26-2005 13:27

HI guys, you can help me? i see here every thing but i am don know mach thing, if you can write for me full script for windows media player for html home page with fullscreen, becouse i writed what you puted here its dont work, maybe i don put in corect area, if you cen write full script, thanks

Tyberius Prime
Paranoid (IV) Mad Scientist with Finglongers

From: Germany
Insane since: Sep 2001

posted posted 12-27-2005 09:53

sorry, drakula, we help, but we don't do your homework, unless you pay for it.

so... get some semi-working examples of what you've been doing, and we might be able to help you.

so long,

->Tyberius Prime

TequilaShot
Neurotic (0) Inmate
Newly admitted

From:
Insane since: Feb 2006

posted posted 02-24-2006 02:53

Hi Guys, I'm having problems implementing the code you've suggested above. All I want to do is make my "full screen" button cause the embeded media player go full screen when it's pressed. All it does is cause the video to stop. This is the code:

code:
<head>
<title>Untitled Document</title>
<meta http-equiv="Content-Type" content="text/html; charset=iso-8859-1">

<script language="JavaScript">
<!--

function fullScreen() {
   var player=document.getElementById("Player"); 
   if (player.DisplaySize==3)  {     // 3 means 'playing'  
     player.fullScreen='true';
   }
}

//-->
</script>

</head>


<OBJECT id='Player' width='320' height='309' classid='CLSID:22d6f312-b0f6-11d0-94ab-0080c74c7e95' 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-oleobject'>
	<param name='fileName' value='vargas_vs_mosley_HiW.wmv'>
	<param name='animationatStart' value='true'>
	<param name='transparentatStart' value='true'>
	<param name='autoStart' value='true'>
	<param name='showControls' value='true'>
	<param name='showStatusBar' value='true'>
	<param name='showDisplay' value='false'>
	<param name='loop' value='false'>
	<Embed type="application/x-mplayer2"
        pluginspage="http://www.microsoft.com/windows/windowsmedia/download/"
        filename="vargas_vs_mosley_HiW.wmv"
        src="vargas_vs_mosley_HiW.wmv"
        Name=MediaPlayer
        ShowControls=1
        ShowDisplay=1
        ShowStatusBar=1
        width=320
        height=309>
    </embed>
	</OBJECT>


<a href="javascript:fullScreen();"><img src="images/fs.gif" width="145" height="73" border="0"></a>



I'm referencing the id as "Player". Any help would be greatly appreciated.

Tyberius Prime
Maniac (V) Mad Scientist with Finglongers

From: Germany
Insane since: Sep 2001

posted posted 02-24-2006 08:40

Without being any kind of expert for this... I guesse

code:
player.fullScreen='true';


should read

code:
player.fullScreen=true;


without the quotes.

so long,

->Tyberius Prime

aabe
Obsessive-Compulsive (I) Inmate

From: UK
Insane since: Apr 2006

posted posted 04-02-2006 14:21

Hello,

I am using the above code to add a Full Screen button to our video presentations.
It is working great in Internet Explorer 6 but it does not work in FireFox.
Does anyone know why that may be?

I noticed another curious niggle, in Firefox the player controls work from the start:
- you can just click the stop button right away as soon as the program starts and it stops.
However, in IE 6, you neet to click the stop button twice. There is a message that says:
"Click to activate and use this control."
Does anyone know why IE 6 does this and FireFox allows the controls to work from the start?

Here is a link to one of our presentations so you can see what the problem is:
http://worldinvisible.com/avlib/w_vid_play_id.mv?vid_id=259

Thanks for your help

aabe

(Edited by aabe on 04-02-2006 14:24)

Tyberius Prime
Maniac (V) Mad Scientist with Finglongers

From: Germany
Insane since: Sep 2001

posted posted 04-03-2006 08:10

well, at least for your IE - you have to klick the player twice - problem see google about 'eolas patent internet explorer'...

aabe
Obsessive-Compulsive (I) Inmate

From: UK
Insane since: Apr 2006

posted posted 04-08-2006 13:10

Thanks Tyberius Prime,

I did the Google search and read the information. "Oh the joys of the Internet and programming." This reminds me of the GIF copywrite problem. Do you think it will be more serious. Aaman Lamba at http://blogcritics.org/archives/2006/04/06/164543.php says it could be a mini Y2k. Anyway, who said the life of a webmaster would be easy!

aabe

chandra_kommoju
Neurotic (0) Inmate
Newly admitted

From:
Insane since: Jun 2006

posted posted 06-09-2006 08:32

Hi,

I created one custom control for mediaplayer, i accessed this control from code behind file(c#.net), it is working find in IE. But when i am trying to load the same page in Mozilla or Netscape player is not showing.
please give me solution for this. If i use html code then it is working fine, but i want to use custom control because dynamically change the file name through code behind (c#.net) file in asp.net.

Thanks in advance.
Chandra.

SameerAlam
Neurotic (0) Inmate
Newly admitted

From:
Insane since: Aug 2006

posted posted 09-01-2006 16:06

Hi, this code doesn't work with my media player, it says error on page.

IQNINE
Neurotic (0) Inmate
Newly admitted

From:
Insane since: Sep 2006

posted posted 09-26-2006 22:39

The Windows Media plug-in (which means Windows Media running embedded in all non-IE browsers) can not be controlled using JavaScript. Microsoft omitted the XPConnect layer that allows JavaScript to talk to the WMP control. [Google XPConnect]

This is a widely known issue. Microsoft has not plans to allow their WMP plug-in (but not ActiveX control) to be scripted using JavaScript. Why would they, frankly? That would make the user experience better in browser that aren't theirs, hence lowering their marketshare?

Note: When I say "plug-in" above, that implies "all non-IE browsers". IE does not support plug-ins. MS dropped that support in IE 5.5, I believe, about 8 years ago. IE only supports ActiveX controls. The WMP that runs in IE is an ActiveX control, so it CAN be scripted using JavaScript. The WMP that runs in non-IE browsers is a "Netscape-style plug-in" or simply "plug-in".

IQNINE
Obsessive-Compulsive (I) Inmate

From:
Insane since: Sep 2006

posted posted 09-26-2006 23:17

So, to answer your question, Windows Media in non-IE browswers can not be made to spawn full-screen through clicking a button/link on a web page, via any params in the embed tag, or any other means.

On the other hand, QuickTime is fully scriptable in all browsers, but it can not be spawned fullscreen through JavaScript either - because the free version of QuickTime does not support full-screen playback. Although, there are "hacky" ways around this you can find online that involve using dynamic QTL file on the server-side.

[I build browser-based video-on-demand servers for a living. These discoveries came about through much pain and toil.]

jonny1234
Neurotic (0) Inmate
Newly admitted

From:
Insane since: Dec 2006

posted posted 12-14-2006 16:00

Ok you folks seem to know what yr saying... at least it sounds that way. So despite the fact that
we can't access WMP embedded in a web page using js, we know you can at least control some
aspects of it's function usings param tags. The question I have for u gurus iz:

Can one DISABLE the default double-click-goes-to-full-screen property of WMP embedded in a
web page?

muchas gracias!
jon

(Edited by jonny1234 on 12-14-2006 16:01)

zit1343
Neurotic (0) Inmate
Newly admitted

From:
Insane since: Jun 2010

posted posted 06-01-2010 18:02

Hey
can someone provide me or explain me how can I make windows media player full screen automatical after it starts playing
please help me
thank you

chinamimi
Neurotic (0) Inmate
Newly admitted

From:
Insane since: Sep 2010

posted posted 09-28-2010 04:09

Hello everybody, I'm new member, to a lot of attention! Thank you! ! Hope that we have more exchanges! !

It really useful for me. Thanks.











________________________
ugg boots
ugg schuhe

flashfango
Nervous Wreck (II) Inmate

From:
Insane since: Oct 2010

posted posted 10-28-2010 07:40

i am newbie to this forum, and thanks for all the sharing information. it does help me!


edit tp: links removed

(Edited by Tyberius Prime on 10-28-2010 17:23)



Post Reply
 
Your User Name:
Your Password:
Login Options:
 
Your Text:
Loading...
Options:


« BackwardsOnwards »

Show Forum Drop Down Menu