I looked into it. It will not work from your local computer directly. It needs to be on a webserver. Of course, if you have WAMP (XAMP), EasyPHP, some other WebServer installed on your computer, or just Apache, then it will work.
The youtube script uses a method to determine your protocol, and will rebuild the link based on that. Or if you really want to use it on your LOCAL computer without any web server hosting it, you could do like this:
Open jquery.youtubepopup.min.js with notepad or notepad++ and find the following lines:
function getYouTubePlayer(URL, width, height) {
var YouTubePlayer = '<iframe title="YouTube video player" style="margin:0; padding:0;" width="' + width + '" ';
YouTubePlayer += 'height="' + height + '" src="' + URL + '" frameborder="0" allowfullscreen></iframe>';
return YouTubePlayer;
}
and change them to:
function getYouTubePlayer(URL, width, height) {
var YouTubePlayer = '<iframe title="YouTube video player" style="margin:0; padding:0;" width="' + width + '" ';
URL=URL.replace("file:","http:");
YouTubePlayer += 'height="' + height + '" src="' + URL + '" frameborder="0" allowfullscreen></iframe>';
return YouTubePlayer;
}
Emil