Login Register

Lightbox

TODO: Fill in info on dojox.image.Lightbox / finish / elaborate more

dojox.image.Lightbox

A clone of Lightbox2 for dojo. A Lightbox displays images in a modal dialog. It can display single images, or image groups, with smooth transition animations in between. You can populate the Lightbox group from a dojo.data datastore, or from markup.

Basic Usage

Being a clone, it is almost completely backwards compatible with Lightbox2. The Lightbox will display the image linked to in an anchor tag. Using a Lightbox is as easy as adding a dojoType to a link tag:

show image1

Grouping images together is as simple as adding a group="" attribute. In this example, the first image is a single view, the other two popup a Lightbox with [previous] and [next] navigation, and 2 images in a group.

show image1
show image2
show image3

Your anchor text can be anything: a thumnail of the image to show, text, etc. It can also be anywhere on a page.

With JavaScript disabled, the natural link to the image will pass through, and display the image natively