1

I, am newbie in jquery plugins.

I've included jquery fancybox plugin on my site and it works perfect, but I want it to only popup my images not slide them.

Pics are on the different parts of the page so they are not logically connected with each other.

I am using this code :

$('.fancybox').fancybox();

and the images have class "fancybox"

Huangism
  • 16,278
  • 7
  • 48
  • 74
Eugene
  • 13
  • 1
  • 6

1 Answers1

0

just remove the rel attribute from your links with class="fancybox" like

<a class="fancybox" href="01.jpg">image 01</a>
<a class="fancybox" href="02.jpg">image 02</a>

then use can use this code

jQuery(document).ready(function () {
    $(".fancybox").fancybox();
});

See JSFIDDLE

JFK
  • 40,963
  • 31
  • 133
  • 306
  • thnx, that helped me, btw u can create your own sub galleries using this "rel" attribute – Eugene Sep 25 '14 at 06:55
  • yes, just bear in mind that members of the same gallery should share the same `rel` and `class` attributes, for instance gallery 1 all links should have ` – JFK Sep 25 '14 at 07:03