Lightboxes, or modal overlays, are commonly used to present large images and other media on a website. Although there are numerous plugins in the WordPress Plugin Directory that offer a similar functionality, I decided to create my own.
The lightbox script of my choice is prettyPhoto, mainly because it is visually appealing, exceedingly versatile and yet still relatively lightweight (~ 21 kb minified, ~6 kb minified & gzipped). prettyPhoto is a jQuery lightbox clone that supports a wide range of different media types including images, videos (YouTube, vimeo or the like), Flash, iframes and inline content, making it a “full blown media lightbox”.
prettyPhoto is being developed by Stephane Caron, who kindly agreed to change the licensing terms of his code to make it GPL compatible following a request by the WordPress plugin support team. As the developer states, prettyPhoto is “totally free to use (…) in all projects, even commercial ones”. For detailed information on prettyPhoto please visit the project page.
Please consider donating to the developer to support prettyPhoto.
The prettyPhoto Media plugin offers a convenient way to add the prettyPhoto lightbox / modal overlay functionality to any WordPress post or page.