Support » Plugin: jQuery Colorbox » [Plugin: jQuery Colorbox] colorbox-manual added to IMG tag, not A tag

  • @techotronic,

    I just updated to the latest version of your plugin, and thinks went wrong on the site I’m developing. The plugin is adding class=”cboxElement” to A tag hyperlinks for images on posts ONLY and not to pages or other places. The plugin adds “colorbox-manual” to the IMG tags elsewhere, but NOT to the A tag. This is resulting in the colorbox not working on non-posts.

    Example on Resulting Post (Where it Works):

    <a class="cboxElement" href="/image.jpg">
     <img class="size-thumbnail imgleft colorbox-890" width="90" height="60" src="/image.jpg" alt="Image Test" title="Image Test">
    </a>

    Example on a Resulting Page (Where it DOESN’T Work):

    <a href="/image.jpg">
     <img class="size-thumbnail imgleft colorbox-manual" width="90" height="60" src="/image.jpg" alt="Image Test" title="Image Test">
    </a>

    Other factors: I am using timthumb and also cformsII (ver 11.5). Although everything was working just fine BEFORE the upgrade.

Viewing 8 replies - 1 through 8 (of 8 total)
  • Plugin Author techotronic

    (@techotronic)

    Hi,

    I just tested WordPress 3.0.1, CFormsII 11.5 and Colorbox 3.6 and I could not reproduce your problem.
    Images on posts and pages work without problems.

    Cheers,
    Arne

    Arne,

    What does the resulting code look like on your end? Is it the same as my end? Any ideas what would cause the different handling?

    Thanks!

    I found out what the problem is… the “Sharebar” plugin conflicts with Colorbox. I really like the Sharebar plugin, but I can’t have a messed up Colorbox!

    Any ideas what to look for in the Sharebar plugin to fix the conflict, or am I best to just dump it and look for something else?

    Thanks,
    Drew

    Plugin Author techotronic

    (@techotronic)

    Hey Drew,
    I just installed the Sharebar plugin in addition to the stuff I mentioned earlier. Also no problem here.
    The theme I am using is a childtheme of “thematic”. Maybe it has something to do with the theme you are developing?

    I personally use “SexyBookmarks” on my website.
    Maybe this would be an alternative?
    (http://www.shareaholic.com/sexybookmarks)
    Cheers,
    Arne

    I’ve been using your colorbox plugin for a few weeks on the site I’ve been developing, and it’s been working great, no issues. I installed the update the same day I installed Sharebar, hence my thoughts that the update was the cause.

    This morning, I started going through the plugins, deactivating one at a time. It is definitely teh sharebar plugin causing the problem – not sure why. I’ve seen a couple, the one I was using was from devgrow.com. Now that I disabled it, I am good to go with your colorbox plugin. It’s definitely not theme related in my case.

    I’ve used sexybookmarks before, but I liked the floating bar idea. I’ll keep looking into it to see why it conflicts.

    Thanks,
    Drew

    Ok, so I know I shouldn’t be asking for your support on a different plugin now, but I found the cause — just not programatically. So the Colorbox works properly if the Sharebar Settings are ENABLED for Pages (and single posts of course). But I don’t want to show the sharebar on pages, only on posts. So when I disable it on Pages, the colorbox no longer works. If I enable it on pages, the colorbox works. Does that give you any idea what might be the conflict code-wise?

    Thanks again – for a great colorbox implementation and your help on this conflict. I know you could have just said to drop the sharebar plugin!

    Drew

    Plugin Author techotronic

    (@techotronic)

    Hi Drew,
    ok, so that is the problem – if you disable the plugin for pages, the JavaScript fails with the message:
    jQuery(sharebar).offset() is null
    After that, my plugin can’t execute the necessary JavaScript any more, so the Colorbox won’t open if you click on a thumbnail.
    I guess you’ll have to open a bug report for Sharebar if you want to keep using it with any plugin that also uses jQuery/JavaScript.
    Cheers,
    Arne

    Plugin Author techotronic

    (@techotronic)

    one more thing about Sharebar:
    To do it’s magic, it includes over 20 different resources from different websites (Facebook, Twitter, Google …) which is definitely not a good idea for a website.
    Sexybookmarks only uses one image and one JavaScript-file which is much more efficient since the number of HTTP connections necessary to load a website should be as few as possible. See:
    http://developer.yahoo.com/performance/rules.html

Viewing 8 replies - 1 through 8 (of 8 total)
  • The topic ‘[Plugin: jQuery Colorbox] colorbox-manual added to IMG tag, not A tag’ is closed to new replies.