add document.location.protocol to src of html5 youtube video

This commit is contained in:
Ernie Park
2012-02-06 11:19:17 -05:00
parent 2ff504e881
commit 15d339ba3e

View File

@@ -10,7 +10,7 @@ if (swfobject.hasFlashPlayerVersion("10.1")){
} else {
//end of this URL may need &origin=http://..... once pushed to production to prevent XSS
$("#html5_player").attr("src", "http://www.youtube.com/embed/" + streams["1.0"] + "?enablejsapi=1&controls=0");
$("#html5_player").attr("src", document.location.protocol + "//www.youtube.com/embed/" + streams["1.0"] + "?enablejsapi=1&controls=0");
$("#html5_player").show();
var tag = document.createElement('script');