Name is required.
Email address is required.
Invalid email address
Answer is required.
Exceeding max length of 5KB

JWPlayer Function pause() and stop() aren't working?


I've been trying to pause the player when the onReady() event is fired but nothing happens and the player will just play the video.

I added in an alert to test if the onReady() event was being called, and it was the alert message appeared.

But When I try to pause or stop the video nothing happens, I've tested seek(), and setFullscreen() and they work fine.

I even download a new file straight from the developer section, but the issue still exists.

I've checked the console and no JavaScript issues show up.

Any ideas on this?

Demo: http://elvis.rowan.edu/~majeko02/Events/EventTests.html

5 Community Answers

JW Player

User  
0 rated :

Works OK for me...

bc.. <script src="jwplayer.min.js"></script>

<div id="media">Player loading...</div>

<script type="text/javascript">
jwplayer('media').setup
(
{
'file': 'http://test.videodetective.net/svideo-mp4-750/mp4/750/3116/130893.mp4?c=025469&r=750&s=130893&d=152&sub=&ref=&fmt=4&e=20110107210326&h=0f80f2f4e77ff07b2e10e',
'provider': 'video',
'width': '640',
'height': '420',
'image': 'http://content.internetvideoarchive.com/content/photos/6871/28860812_.jpg',
'volume': '90',
'autostart': 'false'
}
);
</script>

<script type="text/javascript">
jwplayer().onReady
(
function()
{
alert('Player Ready');
functionCallTest();
}
);


function functionCallTest()
{
alert('functionCallTest');
//jwplayer().pause(true);
jwplayer().play(true);
//jwplayer().seek(60); //...can't seek unless you're using a streaming server
};
</script>



JW Player

User  
2 rated :

I'm using Chrome and it doesn't pause.

JW Player

User  
0 rated :


Tested on Chrome and it does pause.

Test Page:bc.. http://willswonders.myip.org:8088/HTML5/Jeff-1.html



JW Player

User  
0 rated :

Your link is not pausing for me as well.

Here's what I get http://www.youtube.com/watch?v=5t902LHoE2s

JW Player

User  
-2 rated :

Tested on many browsers; many operating systems.

Ifbc.. jwplayer().pause(true);
(active), the player always pauses.

Ifbc.. //jwplayer().pause(true);
(inactive), the player never pauses.

End of story...

This question has received the maximum number of answers.