Configurable settings

Sutharsan - September 25, 2007 - 13:25
Project:jQuery Lightbox
Version:5.x-1.1
Component:JavaScript
Category:task
Priority:normal
Assigned:Unassigned
Status:active
Description

In a website which is installed in a subdirectory, the Close button below the Lightboxed-image is not shown.
Changing the image path (using Firebug) from /sites/all/modules/jlightbox/images/closelabel.gif to /mysubdir/sites/all/modules/jlightbox/images/closelabel.gif makes the image appear. The same goes for the 'loading.gif' image.

#1

sun - September 25, 2007 - 15:26
Title:No Close and Loading image shown» Configurable settings
Category:bug report» task

Yes, we need some work on that. The whole jLightbox settings need to be configurable through the module.
Settings could be implemented through drupal_add_js(). However, I'm not sure if it is the best practice to output them on all pages. On the other hand, we do not know on which pages jLightbox is needed, since images can be contained in any content or block and provided by any content type.

I'm not yet sure, how this could be handled properly. The first option is obviously to output all settings on all pages (which would lead to some overhead). The second one is to generate a jlightbox.settings.js file in the files directory which would setup jlightbox and invoke its initialization.

#2

aparna.mk - March 6, 2009 - 10:23

To get the close button on your jlightbox change jlightbox.css
#lightbox a img{
border: none;
visibility:hidden;
}
and
#imageData #bottomNavClose{
width: 24px; height:20px; float: right; padding-bottom: 0.7em; background: url(../images/close.gif) no-repeat; }
In #imageData #bottomNavClose you can set the image url,here i used close.gif

 
 

Drupal is a registered trademark of Dries Buytaert.