Web – Video – Graphic Design
Posts tagged plugin
Adding A Zenphoto Gallery To Your Wordpress
Jan 16th
I tend to be a very trigger happy photographer. Whether it is with my own Canon point-and-shoot or with my sister’s borrowed Nikon D100, I love taking a lot of pictures. I also like to share those on the web. I started getting into Flickr sharing but quickly discovered that I wanted to share more images than I was able to on their free service. As a designer and operator of some of my own web sites, I found it more cost effective to host the images myself but desired the simplicity and functionality of a service like Flickr. That’s when I came across Zenphoto.
Zenphoto is a database driven application written in PHP that is built with a clean and customizable backend for managing photo galleries on a web site. Zenphoto allows you to upload images directly from the web interface as well as by FTP. It also is easily customized with themes available to change the public facing side of the gallery. I have built a few different nice looking themes for Zenphoto but until recently, when a visitor to my blog chose to look at my gallery, they would invariably feel as though they transitioned to another web site as the Zenphoto gallery was never a perfect match for the blog.
Finally, I have integrated Zenphoto into my Wordpress blog. I have already been enjoying the integration and have plans for many other improvements with how they work together, but I thought I’d share what I’ve done thus far for anyone interested.
Here is where I got the files and a place to start from. He does a very good job simplifying things. http://tech.einaregilsson.com/2007/08/06/integrating-zenphoto-into-wordpress/
To follow some of this, a little understanding of PHP may be required.
Copy the wordpress-integration-zp-theme folder into your zenphoto/themes folder and then in Zenphoto choose Options and activate the theme called ‘Wordpress Integration Theme’.
Copy the files (zp-index.php, zp-image.php, zp-album.php, zp-style.css) from the wordpress-theme-files folder into your current Wordpress theme folder, /wp-content/themes/yourthemename. You’ll see the files now when you go to edit your theme from within Wordpress.
Your installation of Zenphoto should be within the Wordpress folder on your server. ( yoursite.com/zenphoto/ ) When you get the zen-integration.php file from the link I listed above, put it in the plugins folder and activated it in Wordpress, it will install a link to your Zenphoto into the management panel. From this point, some PHP and template alterations will be required from your Wordpress theme editor to make it look the way you want it to. Basically, at this point, Zenphoto should be displaying in the content area on your photo page.
To this point I haven’t completely integrated the Zenphoto management into the Wordpress template so when you use the link to the Zenphoto management console, you essentially leave Wordpress. So to improve flow, I added a link back to the Wordpress management page.
To do this, you just have to create the link in zp-core/admin-functions.php. In the function printLogoAndLinks(), I inserted “| <a href=\”/wp-admin/\”>”.gettext(“Wordpress”).”</a> ”.
Please let me know if you’ve got any questions or suggestions.


