Skip to content

Instantly share code, notes, and snippets.

@rads
Created February 22, 2010 21:15
Show Gist options
  • Save rads/311507 to your computer and use it in GitHub Desktop.
Save rads/311507 to your computer and use it in GitHub Desktop.
function playVideo(videoid, url, lectureid) {
var spinner = $("<img>").attr({
src: "http://dev.videos.med.wisc.edu/javascripts/spinner.gif",
width: 16,
height: 16
});
spinner.insertAfter('a:contains("(2.0x)")');
window.setTimeout(function() {
spinner.fadeOut('slow', function() { $(this).remove(); });
}, 5000);
$("<embed>").attr({
width: 1,
height: 1,
autohref: true,
autoplay: false,
target: "quicktimeplayer",
dontflattenwhensaving: true,
kioskmode: true,
cache: true,
href: url,
src: url
}).appendTo("body");
return false;
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment