Warning: file_get_contents(/data/phpspider/zhask/data//catemap/9/javascript/423.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
Javascript 将previwe图像添加到Fancybox中的jwplayer_Javascript_Jquery_Fancybox 2_Jwplayer6 - Fatal编程技术网

Javascript 将previwe图像添加到Fancybox中的jwplayer

Javascript 将previwe图像添加到Fancybox中的jwplayer,javascript,jquery,fancybox-2,jwplayer6,Javascript,Jquery,Fancybox 2,Jwplayer6,我正在尝试将预览图像添加到中建议的jwplayer中 对于本地各种类型的音频文件,我使用类似“this”的建议方法,但它不适合我(建议的方法适合我,谢谢) 可能是image:this,myphoto,应该是image:$(this.element).attr(“myphoto”),@JFK非常感谢,这就是作品:) <a class="fancybox" rel="group" title="Video 1" data-fancybox-type="anything" containerty

我正在尝试将预览图像添加到中建议的jwplayer中 对于本地各种类型的音频文件,我使用类似“this”的建议方法,但它不适合我(建议的方法适合我,谢谢)


可能是
image:this,myphoto,
应该是
image:$(this.element).attr(“myphoto”),
@JFK非常感谢,这就是作品:)
<a class="fancybox" rel="group" title="Video 1" data-fancybox-type="anything" containertype="video" href="1.mp3" myphoto="1.jpg">
afterShow: function(){ if($(this.element).attr('containertype')=='video'){ jwplayer("video_container").setup({ flashplayer: "jwplayer.flash.swf", file: this.href, image: this, myphoto, autostart: 'true' }); // jwplayer setup }; }// afterShow }); // fancybox ...