Lazy-K Gallery

Copyright 2006 Korey Atterberry

Description

The Lazy-K Gallery is a WordPress plugin that tries to make creating a photo gallery on a website as easy as possible.  It is based on “Lazy Gallery” by Nicholas Bruun Jespersen.

Lazy-K Gallery allows a photo gallery to be embedded onto a WordPress Page.  It doesn’t require complex configuration and relies on the user uploading image files manually into a folder structure (via FTP, etc.) instead of using a web interface.

Lazy-K Gallery offers the following features:

  • easy image uploading and management via FTP
  • integration into WordPress as a true plugin
  • thumbnail and slide caching
  • ability to comment on each image or folder individually
  • optionally use Lightbox or Thickbox for displaying images
  • include a gallery on a WordPress page or blog post
  • display just a portion of your gallery using “subgalleries”

For an example of Lazy-K Gallery in action, see my Example Gallery or any of these fine websites. You might also take a look at my FAQ page for more information an using Lazy-K Gallery. Need help? Take a look in the forums.

Download

The latest version of Lazy-K Gallery is 1.4. Download it with the link below:

If you’re upgrading from a version prior to 1.3, I’d recommend you visit the Cache Manager from the options page and rebuild your cached images. If you have any problems, drop me a line and I’ll help you out. Old versions and a list of changes can be found on the Version History page.

Basic Installation:

  1. Create a folder inside your WordPress installation directory for your photos and upload them into whatever directory structure you want. You may need to change the permissions on that folder to 755.
  2. Copy the lazy-k-gallery.php file and the lazy-k-gallery folder into your WordPress plugins directory (wp-content/plugins).
  3. Activate the Lazy-K Gallery plugin from the Admin Panel > Plugins screen.
  4. In Admin Panel > Options > Lazy-K Gallery, enter the root directory for your photos folder and modify the other settings if you want to.
  5. Hit the “Create Page” button. It will create a page for the gallery. You can edit it if you’d like to change the title, body, slug, etc.

Advanced Setup:

Once you’ve performed the basic steps above you should be ready to go. All of the steps below are optional.

Page creation

If the “Create Page” button doesn’t work, you can create the gallery page manually. Create a new WordPress Page and enter the text <!–lazy-k-gallery–> where you want the photo gallery to appear.

Pre-creating slides and thumbnails

If you want to create your thumbnails and slides ahead right away, you can use the cache manager. If you don’t create these, the first time someone visits a folder within your gallery they will experience a delay.

Visit the Cache Manager from the options page. Check the “create” checkboxes to create all your thumbnails and slides. If you want to recreate existing thumbnails and slides, use the “delete” and “create” checkboxes.

Enable per-picture commenting

If you want to enable commenting on each image/folder individually, you will need to edit your comments template within your theme. Edit the following file within your WordPress installation:

wp-content/themes/default/comments.php

If you are using a theme other than “default”, edit the file within that theme’s folder instead. You could also edit this file from your admin panel by choosing Presentation > Theme Editor > Comments.

You should have a couple of lines that look something like:


<!-- You can start editing here. -->

<?php if ($comments) : ?>

Put the following line between them:

<?php if (function_exists('lzk_filter_comments')) {$comments = lzk_filter_comments($comments);} ?>

If you have any problems with making that change, just send me a note and I’ll help edit your comments.php file.

Creating Subgalleries

A “subgallery” is just a subset of your full gallery, starting at a given directory. Using subgalleries, you can essentially have multiple galleries on one site. Also, you might use this feature to share just a portion of your gallery in a post or page. Let’s say you’ve uploaded a new folder to your gallery – you could include just that folder in a subgallery in a blog post.

To display a subgallery, create a post or page and include the following tag:

<!--lazy-k-gallery:subgallery=Animals-->

This tag will display a subgallery consisting of all your photos from the “Animals” folder in the root of your gallery.

Known Issues

  • In order to make per-picture commenting work, you have to edit the comment template in your theme. Hopefully WordPress will add a hook for this filter in a future version.

These issues will be addressed in future releases.  Please leave any other suggestions using the comments form below.  Keep in mind the goal is to keep this plugin simple.  There are other gallery plugins available that are much more powerful than this one. I do have a list of planned improvements that I’m considering.

Acknowledgements

Thanks to…

  • Nicholas Bruun Jespersen for creating the original Lazy Gallery.
  • Marius Kroon and Will for helping work out the initial bugs
  • Mark Jaquith and “io_error” for help in coding the per-picture commenting
  • Paul Kimbrel for help setting up the Ajax stuff
  • Garrett Bartley for solving a problem with single quotes in file/folder names
  • Mike for help with dots in file names and replace underscores feature
  • Bent Graphics for testing help
  • Josip Medjumurac for help with integrating with Thickbox
  • Adeola Awoyemi, Tim Rowe and Sascha for finding and helping to correct some issues

License

This program is free software; you can redistribute it and/or modify it under the terms of the GNU General Public License as published by the Free Software Foundation; either version 2 of the License, or (at your option) any later version.

This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for more details.

You should have received a copy of the GNU General Public License along with this program; if not, write to the Free Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA

180 Responses to “Lazy-K Gallery”

  1. Lu says:

    Hi! I love this plugin and I’d like to know if it will work fine with WordPress 2.1…
    Tks!

  2. Michael says:

    First off, the user must chmod 777 the photos dir she/he creates for all the photos or the lazy-k-thumbs folder will not be created and therefore you phots will not show up at all.

    The Web server needs to have write access to the directory. If the Web server owns the directory, 755 will do. However, if you create the folder with an FTP client or cPanel, it will be owned by another user and then you would need 777, which would also allow outsiders to write to it.

    From the brief look I took, I like your gallery, and I will fiddle with it in the next few days.

  3. Petter says:

    Lu: I have this plugin working with WordPress 2.1.

  4. Eliot57 says:

    Hi!

    First, sorry for my english, I’m spanish.
    I’m using WordPress 2.1 and K2 with Style Blue-K2.

    I have 2 problems. The first is a problem with the thumbnails an the “li” tag, I think, and my thumbs are very very little, but with the solution posted in Foro doesn’t work on my gallery with firefox, in IE work’s fine.

    [code]
    #gallery div.thumbs li
    {
    list-style-image: none;

  5. Eliot57 says:

    Sorry for repeat, it seems that the code comments anything :(

    Hi!

    First, sorry for my english, I’m spanish.
    I’m using WordPress 2.1 and K2 with Style Blue-K2.

    I have 2 problems. The first is a problem with the thumbnails an the “li” tag, I think, and my thumbs are very very little, but with the solution posted in Foro doesn’t work on my gallery with firefox, in IE work’s fine.

    [Code]
    #gallery div.thumbs li
    {
    list-style-image: none; — Added
    list-style-type: none; – Added
    background: #dddddd;
    vertical-align: top;
    text-align: center;
    float: left;
    padding: .6em;
    margin: .5em;
    }
    [/code]

    This is my page is you want to see it: http://www.miscoris.com/piter/wordpress/index.php/fotos/

    The second problem is on my wife's blog ( http://www.miscoris.com/wordpress/index.php/fotos/?lzkfile=Prueba%2FDSC03828.JPG ).
    When you click on a photo, the container of Prev and next buttons are very long. Do you have a solution for this?
    She is using WordPress 2.0.5 with Tulip Time Theme.

    Excuse the annoyances and thank's for all

  6. Albert says:

    Hey Korey,

    Thanks for the great gallery. I’m having trouble with the cache manager and I’m not sure if I’ve got something set wrong. All my folders are set to 777 but the cache manager won’t do anything. Whichever of the check boxes I check, it just sits on step 0 of whatever it’s trying to do and hangs. I’ve tried to go in and manually delete the thumbnails folders with FTP and I don’t have permission to do it for some reason. Any ideas?

    Thanks,

    Albert

  7. Minosse says:

    Hello Korey, I have installed yours plugin Lazy K Gallery and I find it very interesting but I have found a problem. In the sidebar I have the plugin get recent comments and if clicca on the link of a comment made to an image she is come it sends back you to the main page of the gallery and not to that one of the really commented photography. Is a solvable problem?

  8. daive says:

    Hello Korey, nice work on here.. that pluggin look like what i need. But when i start creating thumbnails it say that :

    Current progress:
    Processing test/bc-ava.jpg…
    Processed 0 out of 3 images. 0 errors

    No thumbs and folders associated are created. I’ve set all folders to 777 as well.. Any ideas of my trouble? Because i got no error. I’ve created the page with the code but it show nothing. Thx for helping! :)

  9. patric says:

    for some reason ican get the gallery to work. the create page button doesn’t work for me and building the page manually doesn’t work either. i jut get a blank page displayed… any ideas
    plug in istalled in wp-smoothly

  10. patric says:

    …and when i try to create the thumbs..the process gets stuck on the first pic, but no error is shown

  11. Tess Termulo says:

    Hi. I just want to ask for some help. I’ve recently installed the lazy-k-gallery plugin and lightbox in my blog. I put it in a page but I wanted to have commenting on each image. There isn’t even a comment form in my page. I’m wondering if anyone could help me with this. Thank you. By the way, the page is located here.

  12. Korey says:

    Tess-

    If you’re using the lightbox plugin to view the slide page, there can’t be a comments form on that lightbox popup. If you aren’t using that setting, you just need to set up your page template and page for commenting. There’s an article on that in the FAQ. If you need further help please start a thread in the support forums and I’ll lend a hand.

  13. After I´ve read that long discussion about how to get Lightbox to work with LZKG, I´m happy it just works as I want.

    I just installed Lazy k gallery, and the plugin from http://www.m3nt0r.de/blog/lightbox-wordpress-plugin/

    and it works !

    thank you !!!!!!!!

    Martin

  14. [...] prece a São Google, padroeiro dos curiosos, retorna várias alternativas, das quais destaco o Lazy-K Gallery, pela facilidade de instalação e possibilidade de comentários foto a foto; e o Popup Image [...]

  15. [...] også oversatt. Last ned resultatet her. For en stund siden oversatte jeg WeatherIcon 2.99.122 og Lazy-K-Gallery 1.4 også. Resultatene kan hentes her og her. Filene som kan lastes ned fra mine nettsider er ikke [...]

  16. [...] one… Korey’s WordPress Plugin Site Lazy-K Gallery I have not tried it but it looks [...]

  17. [...] I’ve added another plugin called Lazy-K-Gallery. It seems to work inside wordpress pretty well. All i have to do is upload optimized files into the [...]

  18. [...] WordPress nutzt und diese Möglichkeit noch neu ist, hier die nötigen PlugIns. Lazy-K-gallerie sowie jQuery Lightbox ist nötig. Wer weiß wie man PlugIns installiert, dürfte keine Probleme [...]

  19. [...] Lazy-K Gallery WordPress Plugin Este plugin possibilita a apresentação de galerias de imagens em formato slideshow ou não, oferecendo aos leitores a possibilidade de comentar as imagens ou pastas, individualmente. Poderá criar galerias em páginas ou artigos, e também criar sub-galerias [...]

  20. [...] Lazy-K Gallery WordPress Plugin Este plugin possibilita a apresentação de galerias de imagens em formato slideshow ou não, oferecendo aos leitores a possibilidade de comentar as imagens ou pastas, individualmente. Poderá criar galerias em páginas ou artigos, e também criar sub-galerias [...]

  21. [...] Plugin Lazy-K Gallery von Korey Atterberry bietet folgende Features: Bilder Upload per FTP, Thumbnail und Slide Caching, [...]

  22. [...] la primera imagen publicada usando NextGEN Gallery en lugar de LazyK Gallery. Poco a poco todo el contenido sera migrado a la nueva [...]

Comments on this page are no longer allowed. If you have a question or comment please see the support forums.


6pm coupons | for carbonite | hotel deals