Welcome Guest! To access all forums & features, please register an account or sign-in. → Why register?



fancybox jQuery help!


4 replies to this topic - - - - -

#1 ACTIONpack

    Graphic Designer

  • 1,666 posts
  • Joined: 10-August 03
  • Location: Lawrenceville, GA
  • OS: Windows 8 Pro
  • Phone: HTC Windows 8X

Posted 08 May 2012 - 21:05

I'm using Fancybox plugin and for some reason I can't get the left and right buttons to show up when the image is large on the page. Any reason why it's not working?


http://www.imagraphi...historical.html

http://fancybox.net/


#2 laycat

    Neowinian

  • 55 posts
  • Joined: 25-November 10

Posted 08 May 2012 - 21:19

The links for the images in your source are all the same id, id="example5". Change these to class, and the subsequent jquery calls, see if it makes a difference?

#3 OP ACTIONpack

    Graphic Designer

  • 1,666 posts
  • Joined: 10-August 03
  • Location: Lawrenceville, GA
  • OS: Windows 8 Pro
  • Phone: HTC Windows 8X

Posted 08 May 2012 - 21:30

I try changing it from ID to CLASS in the html and js coding. Didn't work.

#4 laycat

    Neowinian

  • 55 posts
  • Joined: 25-November 10

Posted 08 May 2012 - 21:46

I'm not entirely sure then. At the moment there are 2 fancybox calls when clicking an image... $("a.example5").fancybox({ 'titlePosition' : 'inside' }); and $("a[rel=example_group]").fancybox({ ... }); Perhaps comment one of these out and see if it is this?

Also, as a side note, you have an error in your html. Every 4th anchor element is missing a closing > on the opening tag...

<a class="example5" rel="example_group" href="i/3_b.jpg" title="Lorem ipsum dolor sit amet" <img="" style="margin-right:0;" src="i/1_s.jpg" alt=""></a>

should be...

<a class="example5" rel="example_group" href="i/3_b.jpg" title="Lorem ipsum dolor sit amet"> <img="" style="margin-right:0;" src="i/1_s.jpg" alt=""></a>


#5 OP ACTIONpack

    Graphic Designer

  • 1,666 posts
  • Joined: 10-August 03
  • Location: Lawrenceville, GA
  • OS: Windows 8 Pro
  • Phone: HTC Windows 8X

Posted 08 May 2012 - 22:13

I just got it fix. I decided to change it to the more advance one of Fancybox. Thanks laycat for your help!