I’ve got a dashboard widget that pulls from an RSS feed on my central server and allows anyone using my theme to see newly available skins.
Using the dashboard widget, I’m currently presenting a thumbnail image of the skin along with a description and a link to download. I’d like to enable the thumbnail so that when clicked, it will open the full size image in a lightbox over the wordpress dashboard.
I want to install as little extras as possible to make this possible. My theme is already including jquery-1.4.2.min.js and I’d like to build off that if possible.
Any ideas much appreciated.
WordPress already ships with both jQuery and jQuery UI. Rather than including them manually, you can call them by using
wp_enqueue_script
. I’m personally a big fan of the jQuery UI Dialog setup (which also ships with WordPress) … it should be easy enough to attach a click handler to your thumbnail such that clicking launches a jQuery dialog.