jquery - using Fancybox with 2 ids the same -
i have 2 fancybox iframes same , both on same page - in different places (yes, both necessary). @ present, referenced jquery code:
$(function() { $("#index").fancybox({ 'width' : 615, 'height' : 450, 'autoscale' : true, 'autodimensions' : true, 'transitionin' : 'elastic', 'transitionout' : 'fade', 'overlaycolor' : '#111', 'type' : 'iframe' }); }); // index2 $(function() { $("#index2").fancybox({ 'width' : 615, 'height' : 450, 'autoscale' : true, 'autodimensions' : true, 'transitionin' : 'elastic', 'transitionout' : 'fade', 'overlaycolor' : '#111', 'type' : 'iframe' }); });
i have called them #index , #index2. syntax combine these same function? possible? mean this:
$(function() { $("#index" && "#index2").fancybox({
not familiar fancybox, if can use class selectors instead of ids, give both elements same class, "fancy", , access them via
$('.fancy').fancybox({...
Comments
Post a Comment