Support » Plugin: add-rel-lightbox » Not working in v3.5?

  • Resolved Sue


    I don’t think this plugin is working with WordPress 3.5.

    If images were uploaded and inserted into posts PRIOR to the WP upgrade, they still open in a lightbox…but new images have a problem. It seems like that when this plugin is activated in WordPress 3.5, it prevents the “link URL” field from “sticking”. I link to the file, save…but it doesn’t open in a lightbox. When I check the image link, it has been erased from image.

    I love this plugin! Any chance it will be updated for 3.5?

Viewing 7 replies - 1 through 7 (of 7 total)
  • Plugin Author DefProc


    I hadn’t noticed the problem, as haven’t created any posts with images in 3.5 yet. It’s quite possible that the image attributes have been changed when the image is inserted (which won’t affect earlier posts) so I’ll have a look and see if I can see what’s happening.

    Plugin Author DefProc


    I’ve tried adding images as normal from the media interface in WP3.5 — both singly and in galleries — and it’s all working for me. The plugin only changes the post/page content when the page is rendered for the visitor, no changes are made to the stored version of the post/page.

    Do you still have a problem of the links not appearing as expected if add-rel-lightbox is disabled?

    Do you have any other plugins that operate on the images? For instance, the Slimbox Plugin that I use has a basic preg_replace() for images that I have manually disabled to stop it interfering with add-rel-lightbox.

    Or do you have a page online that I can see the problem you’re having and see if I can see the fault? email to contact [at] if you’d don’t want to post the link in this forum.

    Does that help?



    I think this plugin is working PERFECTLY – once I read your reply, I got to thinking that it is probably the slimbox plugin I was trying to use that was incompatible with 3.5.

    So I used a different plugin for the lightbox effect and all is well! Your plugin works fine!

    Sorry for the false alarm!!!

    Great plugin and I am buying you a cup of coffee for your quick response.

    Plugin Author DefProc


    Thanks very much. Glad I could help. 🙂

    I’ve got it to work on single images but not WP gallery
    wp: 3.5.1
    addrellb: Version 0.4.1

    Works in galleries on WP 3.5 but not on 3.5.1

    Plugin Author DefProc


    @drain0: what form of the gallery shortcode are you using? If you use [gallery] then add-rel-lightbox won’t do anything because this returns a page address. Using [gallery link=file] will ensure it gives the file address.

    For my installation, I’ve been using the Slimbox Plugin as all it really does is add the script tags to the page header (adding these to the theme is the best solution). Unfortunately it also contains the following lines that conflict with add-rel-lightbox, so I’m running a customised version without them.

    function slimbox_create($content){
    return preg_replace('/<a(.*?)href=(.*?) (jpg|jpeg|png|gif|bmp|ico)"(.*?)>/i', '<a$1href=$2.$3" $4 rel="lightbox[roadtrip]">', $content);
    add_filter('the_content', 'slimbox_create', 12);

    Aha Thanks DefProc
    Using [gallery] used to work (?)
    I changed to [gallery link=file] and that does work now.
    (I am using Slimbox Plugin too (those lines are already commented out))

    Thanks again, it’s a handy little plugin.

Viewing 7 replies - 1 through 7 (of 7 total)
  • The topic ‘Not working in v3.5?’ is closed to new replies.