如何用fancybox(http://fancyapps.com/fancybox/demo/ )实现jquery Power Zoom( http://www.dynamicdrive.com/dynamicindex4/powerzoomer.htm)?我已经尝试过这种方式,但仍然无法工作
jQuery("#" + prefixId + "gallery a").fancybox({
transitionIn: 'none',
transitionOut: 'none',
width: contentHeight,
height: contentHeight,
cyclic: true,
onStart: function() {
jQuery("#" + prefixId + "gallery").trigger("pause");
jQuery("img.fancybox-image").addpowerzoom();
console.log('start');
},
onClosed: function() {
jQuery("#" + prefixId + "gallery").trigger("play");
console.log('closed');
},
callbackOnShow: function() {
jQuery("img.fancybox-image").addpowerzoom();
console.log('show');
},
onComplete: function() {
jQuery("img.fancybox-image").addpowerzoom();
console.log('complete');
}
});