• Resolved Ganjica

    (@ganjica)


    Hello,
    first of all thanks for developing such a great plugin! Then here comes my issue: I’m using a theme called Autofocus. It’s an awesome theme, and it has his own overlay for his own galleries. From time to time, I need to add specific images to my posts that are not part of any gallery. In that case, the image link just open the image file, while i’d like to have an overlay as well.
    But if I just activate easy FancyBox, I’ll end up having 2 overlays for every image i click on. This is an example of a page without the plugin activated:

    http://www.ganjica.net/2012/11/14/combine-apc-2/

    The first 6 images are part of Autofocus gallery and cycle on top. The 7th is not, and that’s the image i’d like to activate Fancy box for.

    Is it possible to do it?

    Thanks!

Viewing 2 replies - 1 through 2 (of 2 total)
  • Yes, it should be possible but you might run in to an issue with fancy transition effects because the theme loads it’s own easing extension script…

    If you install Easy FancyBox be sure to deactivate auto-detection of image links. This will prevent FancyBox from binding itself to the gallery images. Then, after inserting a single / stand-alone image, you’ll need to switch to the editors HTML tab and manually give the image link a class="fancybox" attribute. If the link already has a class, then just add fancybox (seperated with a space) to it.

    Thread Starter Ganjica

    (@ganjica)

    Hi, thank you very much for replying so quickly! Your solution works, but only half way. I managed to avoid the auto-load, good! But now Easy fancybox display the overlay only on the formats specified in the autodetect field. The class “fancybox” doesn’t do anything. So I setup easy fancybox to autodetect only JPEG and not JPG, then I made a test post with two versions of the same image, the first is a JPEG, without class fancybox. The second one is a JPG with the class fancybox. The first works, the second one doesn’t.

    Here is the html:

    <img class=”fancybox aligncenter size-large wp-image-721″ title=”banksy2″ src=”http://www.ganjica.net/wp-content/uploads/2013/04/banksy2-494×354.jpg&#8221; alt=”” width=”494″ height=”354″ />

    And here’s the page:

    http://www.ganjica.net/2013/04/22/test-2/

    If I’ll rename all the images I need from jpg to jpeg it’s all good, but it’s a very cheap walkaround. Do you know what did I do wrong?

    Thanks a lot!

Viewing 2 replies - 1 through 2 (of 2 total)
  • The topic ‘Activate overlay only on specific images’ is closed to new replies.