An update for Mango-Lightbox2

As was recently pointed out to me, a bug surfaced where my Lightbox2 plugin wasn't making the necessary configuration change for the advanced tab of the TinyMCE hyperlink dialogue to display in recent versions of Mango.

The bug was basically that some of Mango's code had been moved to a new file. My plugin slightly modifies this code to add the advanced tab, but couldn't find it. I've asked Laura to consider making this some sort of configuration that can be accessed programatically, but for now editing the file will have to do.

The new version of the plugin addresses this bug and is available on the RIAForge project page (or my project page), and in the SVN Repository.

in My projects | Mango Posted 2008-12-09 01:34

4 responses:

Jason Durham
Jason Durham 2008-12-16 8:47 PM #
I just DL'd the plugin, uploaded it to mangoblog/components/plugins/user... saw it in on my add-ons page, clicked "activate" and was greeted with..."Plugin could not be activated"

I've tried re-downloading, uploading and activating with the same result.

-Jason
Mike Henke
Mike Henke 2010-06-09 1:10 PM #
Could you move the js calls to the bottom of the page?

Grade D on Put JavaScript at bottom

There are 7 Javacript scripts found in the head of the document

And limit the calls to only the pages containing lightbox2? I noticed the calls are on every page.
Adam
Adam 2010-06-09 1:38 PM #
Mike,

Moving the includes to the bottom of the page should be possible, but it's not really possible to only include them on pages that lightbox is being used (e.g. don't include it on a single-post page when that post doesn't use lightbox) because I don't think that information is exposed, at least not for the beforeBodyEnd event.

I suppose it might be possible to listen for every post/page content end-event, use a regex to check its content, and then *if* lightbox is used, set a flag that the body-end event checks for... But that could have performance issues if, for example, you show the full-content of your last 20 posts on the home page of the blog. It'd have to run regex against all 20 of those posts.

For what it's worth, I switched to ShadowBox (http://www.visual28.com/articles/shadowbox-plugin) for my own sites, which uses less convoluted JS.
Mike Henke
Mike Henke 2010-06-09 1:58 PM #
Thanks, I might give ShadowBox a look and add the class in the specific page.

Leave a comment:

Leave this field empty: