Hacker News new | ask | show | jobs
by lpinca 4883 days ago
http://jsfiddle.net/mt6Tt/1/

Value is not of type AudioBuffer. Origin null is not allowed by Access-Control-Allow-Origin.

1 comments

This is not a bug in the library, it is a browsers security feature. Audio files can only be played from the same domain that you are trying to play them from because an XHR request is used to fetch the audio file.
Yeah, but it's a limitation.

Playing a file in another domain works with http://www.schillmania.com/projects/soundmanager2/ or http://www.jplayer.org/ (http://jsfiddle.net/Q4LMV/18076/)

https://github.com/CreateJS/SoundJS/ instead respect same origin security policy (http://jsfiddle.net/SeUD7/) like your library.

That being said, i like your lightweight library, well done.