Fancybox iframe 不出现

Fancybox iframe does not appear

HTML

<a class="fancybox fancybox.iframe" href="http://www.youtube.com/embed/L9szn1QQfas">Youtube (iframe)</a>

此代码行有效,但我想动态添加 javascript 代码。

JS

'<li>' +
'<div class="list-left">' +
'<img src="' + thumb + '">' +
'</div>' +
'<div class="list-right">' +
'<a class="fancybox fancybox.iframe" href="http://www.youtube.com/embed/' + videoID + '"><h3>' + title + '</h3></a>' +
'<small>By <span class="Title">' + channelTitle + '</span> on ' + videoDate + '</small>' +
'<p>' + description + '</p>' +
'</div>' +
'</li>' +
'<div class="clearfix"></div>' +
'';

当我点击link时,我无法用fancybox打开。它打开了新页面,控制台显示

Mixed Content: The page at 'https://www.youtube.com/embed/OFMSUI7PAS8'
was loaded over HTTPS, but requested an insecure image 
'http://www.youtube.com/favicon.ico'. This content should also be served over HTTPS.

更新

我刚用了你的pen,一切正常,你忘了把type: 'iframe'传递给fancybox,你也应该把你的js代码放在[=的js部分13=],这里是截图

这里是 codepen 的 link:Click me