WordPress.org

Support

Support » Plugins and Hacks » [Resolved] [Plugin: Easy FancyBox] Shows double images in navigation

[Resolved] [Plugin: Easy FancyBox] Shows double images in navigation

  • myrok24
    Member

    @myrok24

    Hi, when i click on a image, from a set of two in total, the fancybox opens just fine.
    But when i navigate in the box, it shows duplicate images, so four in total. I checked the library and there are no duplicates there.

    Im using fancybox in a wordpress them called “Cudazi Mono”.

    Anyone familiair with this strange problem?

    thnx!

    http://wordpress.org/extend/plugins/easy-fancybox/

Viewing 11 replies - 1 through 11 (of 11 total)
  • Plugin Author RavanH
    Participant

    @ravanh

    got a link?

    Plugin Author RavanH
    Participant

    @ravanh

    You have the thumbnail images wrapped in double anchor tags:

    <a href='http://www.popvanstof.nl/tijdelijk/wp-content/uploads/2011/09/gijsdetail.jpg'>
    <a href='http://www.popvanstof.nl/tijdelijk/wp-content/uploads/2011/09/gijsdetail.jpg' title='gijsdetail'>
    <img width="642" height="426" src="http://www.popvanstof.nl/tijdelijk/wp-content/uploads/2011/09/gijsdetail-642x426.jpg" class="attachment-grid_8" alt="gijsdetail" title="gijsdetail" />
    </a>
    </a>

    (notice the double <a href=... at the start and double </a></a> at the end)

    It’s some sort of slides function in your theme that automatically creates these links? If you can change the above example (same goes for the second one) to the following, FancyBox will no longer show double images:

    <a href='http://www.popvanstof.nl/tijdelijk/wp-content/uploads/2011/09/gijsdetail.jpg' title='gijsdetail'>
    <img width="642" height="426" src="http://www.popvanstof.nl/tijdelijk/wp-content/uploads/2011/09/gijsdetail-642x426.jpg" class="attachment-grid_8" alt="gijsdetail" title="gijsdetail" />
    </a>

    hmm strange.. yeah if it isn’t a fancybox code, then i must seek into the theme ccode i’m afraid.

    Thnx for finding the problem’s source anyway.

    Hi myrok24

    I’m having the same issue with the same theme as you’ve used, did you resolve the problem? If so can you explain how?

    Thanks

    wwww.beckyjones.co.uk

    @ rmj.857

    I’m not 100% certain if this is what i did, but it was solved by a simple setting in the “media settings” –> fancybox part.

    To be more specific: Under “Links”, set the “Exclude” dropdown to –> “Empty (hidden) links” instead of the default “none” setting.

    Let me know if it worked out 🙂

    Plugin Author RavanH
    Participant

    @ravanh

    I’ve downloaded the Mono theme to take a look and as far as I can tell it’s in the function cudazi_attachment_gallery. You can find that in the file /mono/libraries/attahment-gallery.php

    On line 55 you see

    $output .= "<div class='post-thumbnail'><a href='" . $post_thumbnail_src[0] . "'>";

    Change it to $output .= "<div class='post-thumbnail'>"; and on line 57 you see

    $output .= "</a></div>";

    and change that to $output .= "</div>";

    Plugin Author RavanH
    Participant

    @ravanh

    myrok24, that’s brilliant! I did not even expect that option in my own plugin to do the job in this case but you are right, that should work 🙂

    Haha.. You’re welcome 😉

    myrok24, I can’t thank you enough, it worked brilliantly and saved me hours of pulling my hair out

    Thanks again 🙂

    afnikitin
    Member

    @afnikitin

    Wow, I faced with the same problem and I thought there would be kind of tough solution for it. But this found way is exactly what I needed. Thanks to RavanH and myrok24!

Viewing 11 replies - 1 through 11 (of 11 total)
  • The topic ‘[Resolved] [Plugin: Easy FancyBox] Shows double images in navigation’ is closed to new replies.