Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

mb_miniPlayer_changeFile search for 'length' #18

Open
milkotodorov opened this issue Oct 27, 2019 · 1 comment
Open

mb_miniPlayer_changeFile search for 'length' #18

milkotodorov opened this issue Oct 27, 2019 · 1 comment

Comments

@milkotodorov
Copy link

Hello,

using the mb_miniPlayer_changeFile throws the following exception:

jquery.js?ver=1.12.4-wp:2 Uncaught TypeError: Cannot use 'in' operator to search for 'length' in http://www.miaowmusic.com/mp3/Miaow-04-Lismore.mp3
    at s (jquery.js?ver=1.12.4-wp:2)
    at Function.each (jquery.js?ver=1.12.4-wp:2)
    at a.jPlayer._absoluteMediaUrls (jquery.mb.miniAudioPlayer.min.js?ver=1.9.3:10)
    at a.jPlayer.setMedia (jquery.mb.miniAudioPlayer.min.js?ver=1.9.3:10)
    at HTMLDivElement.<anonymous> (jquery.mb.miniAudioPlayer.min.js?ver=1.9.3:9)
    at Function.each (jquery.js?ver=1.12.4-wp:2)
    at a.fn.init.each (jquery.js?ver=1.12.4-wp:2)
    at a.fn.init.a.fn.jPlayer (jquery.mb.miniAudioPlayer.min.js?ver=1.9.3:9)
    at a.fn.init.changeFile [as mb_miniPlayer_changeFile] (jquery.mb.miniAudioPlayer.min.js?ver=1.9.3:8)
    at HTMLButtonElement.onclick ((index):432)

I just test it with a simple example button

<button onclick="$('#mbmaplayer_1').mb_miniPlayer_changeFile('http://www.miaowmusic.com/mp3/Miaow-04-Lismore.mp3',false,'Lismore (mp3)')">Lismore (mp3)</button>
@achilehero
Copy link

Hello!

By looking at the function signature, looks like it was changed, but the documentation is not up to date.
So now it is something like: changeFile: function (media, title).
In that case you can use it like:
$('#mbmaplayer_1').mb_miniPlayer_changeFile({mp3: 'http://www.miaowmusic.com/mp3/Miaow-04-Lismore.mp3'},false)"

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants