I recently started using a WordPress theme for one of my sites called (Modern Business 3 Dark for WordPress) that has built in code for a jQuery based lightbox clone called prettyPhoto. This is a beautiful theme, and a very nice implementation of a lightbox. In fact prettyPhoto is very similar to Lightview, which is the lightbox clone I normally use.
Unfortunately prettyPhoto requires some different code to indicate that images or video should be opened in the lightbox than most of the other clones I’ve used. Typically each image must be tagged with something like rel=”lightbox[ID]“, but for prettyPhoto the required tag is rel=”prettyPhoto[ID]“.
I use lightbox clones all the time, and of course there is no tagging standard between each clone, so for a long time I’ve been using a WordPress plugin called Add Lightbox that automatically adds this code. I modified that plugin to work with prettyPhoto, and I thought I would share my mod here. This really was a very simple mod, but I’m sure that there are thousands of other people using the same theme that I am that have the same problem that I did.
Note that this plugin does not add the the files required for prettyPhoto (it only adds the rel=prettyPhoto[ID] tag)! You have to insert the required files for prettyPhoto into your theme yourself, or use a theme such as Modern Business 3 Dark for WordPress that already includes the code.
Installation
- Download the Free OD Add rel=prettyPhoto WordPress Plugin
- Unzip the file
- Upload it in /wp-content/plugins/ of your WordPress installation
- Activate the Plugin
- That’s All
Changelog
0.2
Minor update to change the name and update the documentation.
0.1
Initial release. Adapted from the Add Lightbox Plugin for WordPress.
Please let me know if you find any issues, bugs, or have ideas for improvements.




