I'm embedding JW Player inside a Fancybox frame. What I'd like to have happen is the video stop playing/loading if the frame is closed. The code, and everything else that I've tried, works in Chrome but never in IE and FF.
What I have currently:
$('.lightbox').fancybox({
//href: jThis.attr('href'),
type: 'inline',
padding: 15,
width: 960,
height: 540,
autoSize: false,
scrolling: 'no',
enableEscapeButton: true,
afterClose: function() {$("#large-video").empty();} //This is what I've tried changing
});
That bottom line, I've tried also just doing "jwplayer().stop()" and "function() {jwplayer().stop()};. Both work just fine in Chrome, but the video continues playing in IE9 and FF. Rather at a loss here. Anyone done this before?