Stop jwplayer 6 hide control panel

I am using jwplayer 6, while the video is playing jwplayer, hides the control bar, and only if we pause the video showing the control bar.

I've tried settings:

jwplayer("jwplayer").setup({
    file: "video/new.mp4",
    image: "img/common/download.jpg",       
    controls : true,
    controlbar.idlehide : false,
    width: 673,
    height: 400
});

      

But its a throwing mistake. Is there any way to stop hiding the control bar.

+3


source to share


4 answers


You can add this to your CSS and should remain visible to the HTML5 player:

.jwplayer .jwcontrolbar {
    display: inline-block !important;
    opacity: 1 !important;
}

      



For those using flash (IE9 and below), I don't know of a solution other than writing your own plugin with custom controls that take longer than it's worth (unless you want a play / pause button?).

+3


source


In jwplayer 6, this is simply not possible. Upgrade to jw5 and it will be helpful.

I think the guys at jwplayer are just stupid. These and other "features" in the new jw6, such as the non-changeable vertical slider, etc., make this player nearly impossible for most of us. Removing very old and used features from the product seems like suicide for the company. This did not happen because there are not many alternatives for jw. In the end, luck will be with this amazingly smart business strategy, jw!



Ps Imagine the geniuses at jwplayer no longer support jw5, so you won't find any documentation on this topic. Also the source code for the older versions is also not available as they switched from the developer platform to github and they "forgot" to move the old player files.

Luck

+1


source


Until the update comes with a plausible solution, we have to make it work.

So, I did this:

var targetId = 'player';

$jwplayer(targetId).onReady(function(){

    this.onPlay(callbackOnPlay);

});

var callbackOnPlay = function(){

    var player = $('#' + targetId),
    controlbar = (player.length) ? player.find('.jw-controls') : $('.jw-controls');

    player.onPlay()

    if (player.length && controlbar.length) {

        //Delay 2s
        setTimeout(function() {
           controlbar.fadeOut();
        }, 2000);

        //Add hover event
        player.hover(
           function() {
              controlbar.fadeIn();
           }, function() {
              controlbar.fadeOut();
           }
        );

    }

};

      

0


source


In JW Player 7.3, you can do this via JS:

   var playerInstance = jwplayer('player');
   playerInstance.setup({ ...your config…});

   playerInstance.onReady(function(){     
      displayControlBar();
   });

   function displayControlBar() {
      var controlBar = document.getElementsByClassName('jw-controlbar jw-background-color jw-reset')[0];
      controlBar.style.display = "block"
   }

      

0


source







All Articles