Search code examples
javascriptjqueryjquery-eventsjplayer

Removing seeking in jPlayer


I'm making an application using jPlayer and I would like to keep most of the default functionality. The playing works fine except that I would like to disable seeking, i.e., the progress bar is displayed but clicking it does not take you to any other point in the song. I've tried:

$('#jquery_jplayer_1').unbind($.jPlayer.event.seeking);

but it doesn't seem to work.

Any help would be nice.


Solution

  • I'm not too familiar with jPlayer, but I'd start by making sure '$.jPlayer.event.seeking' returns a string, and not an event object; unbind() takes a string as it's argument. If that doesn't work, you can try listening for the seeking event, log the event object passed to that function, and get the name from there (to use with unbind()).

    If that fails, here's a guy who's customized jPlayer and looks like he's unbinded some events: http://www.jplayer.org/latest/quick-start-guide/event-ended/

    Good luck!