I have recently discovered that there would be a slight problem when Lightbox and Modalbox co-exist on the same page.
The problem is that the modalbox would pop-up slightly on the right of the screen, before shifting to the middle of the screen at the last minute. This would only happen when lightbox is also present on the same webpage.
This problem is caused by lightbox overwriting/extending the method getWidth, which modalbox relies on. This is defined in the lightbox something like this:
-
Object.extend(Element, {
-
getWidth: function(element) {
-
element = $(element);
-
return element.offsetWidth;
-
},
-
…etc…
and the line this function is defined will depend on the particular version of your lightbox.
To fix this conflicting problem, and assuming you have the Javascript Prototype included in your website, is to comment out from line 2 – line 5 of the above code segment (equivalent to your lightbox file).
Hope this has helped someone out there!

Powerball Record: 13,014 RPM
November 4, 2008 at 8:59 am
Thank you for this posting!
November 4, 2008 at 4:46 pm
No problem, hope this has helped you
November 13, 2008 at 12:10 am
Hi, thanks a bunch for this info, it helps as I’m using Lightbox for a flickr gallery. Im trying to implement Modalbox as well but it doesn’t seem to work in wordpress. Works fine on its own but as soon I try to load it through the CMS it wont work. I am going to have to dig down deeper into the guts of WordPress