Skip to content

loadSrc fail with Safari Windows w/QuickTime #3

@timmhayes

Description

@timmhayes

I'm not sure if I'm doing something wrong, but this seems like a bona fide bug...

I'm using loadSrc() on an audio element. All works correctly in Chrome, IE, and Firefox, but Safari fails to play the updated file. (All play the initially embedded file.)

My initial audio element looks like this:

<audio id="audio" controls="controls">
   <source src="audio/myaudio.mp3" type="audio/mpeg" />
   <source src="audio/myaudio.ogg" type="audio/ogg" />
</audio>

Runtime code looks like this:


var srces = [
      {src:"audio/somenewfile.mp3", type:"audio/mpeg"},
      {src:"audio/somenewfile.ogg", type:"audio/ogg"}
];
$("#audio").loadSrc(srces);

If I inspect the element after running this code, Chrome shows updated child elements. However Safari shows the as empty... meaning Safari wiped out the initial child elements, but did not replace them correctly.

One difference I can see during runtime occurs on line 287 if mm.full.js:
if(fixPreload.addSrces(elem, value, preloadPass)){return;}

Chrome returns false on this, but Safari returns true and drops out of the function, failing to execute what follows... which includes the code that creates the new child elements.

I'm using:
jMediaelement v1.3 (stable build)
Safari 4.0.3
QuickTime Player 7.6.5
Windows XP

Great code otherwise... thanks for putting it out there!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions