Skip to content

Instantly share code, notes, and snippets.

@wayferer
Created February 28, 2014 17:40
Show Gist options
  • Save wayferer/9275734 to your computer and use it in GitHub Desktop.
Save wayferer/9275734 to your computer and use it in GitHub Desktop.
phonegap file path
function getPhoneGapPath() {
var path = window.location.pathname;
path = path.substr( path, path.length - 10 );
return 'file://' + path;
}
var snd = new Media( getPhoneGapPath() + 'test.wav' );
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment