Pergunta

I am working on a program in wich i need to use up to 4 instances of the jPlayer mp3 player.

All seems to be working fine, but when i play all of them, 1 by 1 the following happens.

I play the items, and when i try to play them once again, it seems to somehow not rewind all the way to the beginning of the soundstrack. It either starts at the last seconds, and you hear a sound like tss or something. or it randomly starts somewhere in the middle.

But on the other hand, sometimes it does work, and it plays smooth as silk. I just use the standard jquery from the jPlayer site. Only thing i changed is CSS and some HTML.

HTML is as follows:

<div id="cp_container_1" class="cp-container">
     <div class="cp-circle-control"></div>
         <ul class="cp-controls">
             <li><a class="cp-play" tabindex="1">play</a></li>
             <li><a class="cp-pause" style="display:none;" tabindex="1">pause</a></li> <!-- Needs the inline style here, or jQuery.show() uses display:inline instead of display:block -->
         </ul>
</div>

The jquery that loads the source for the player is as followS:

                <script type="text/javascript">
                $(document).ready(function(){
                    var myCirclePlayer = new CirclePlayer("#jquery_jplayer_1",
                    {
                        mp3: "'.MEDIA_PATH.$questionResult->vraaggeluid.'"
                    }, {
                        cssSelectorAncestor: "#cp_container_1",
                        swfPath: "script/jplayer",
                        wmode: "window",
                        solution: "flash,html",
                        supplied: "mp3"
                    });                       
                });
                </script>

Anyone that can help me? the script above is combined with PHP, it's in an echo. I also tried using static values as a source, but that wouldn't help.

Foi útil?

Solução

For the sake of users looking for answers on this question, try looking into HTML5. I have been using HTML5 in combination with jQuery to fit multiple instances of mp3 and videoplayers into my applications. It works like a charm, no jQueryplayer that can beat the lvl of simplicity on that.

Licenciado em: CC-BY-SA com atribuição
Não afiliado a StackOverflow
scroll top