Picturegrid Wordpress Plugin

The above selection of photos have been embedded using the Picturegrid Wordpress Plugin. Lightbox is turned off, so each image links to the appropriate page, and image borders and image margins are set to zero. These photos are all from my set “Favourites”

The Picturegrid wordpress plugin allows you to import your Flickr images into your sidebar, or onto any page. In fact you only need to call the function picturegrid(); inside any php to show the grid using the settings set on the options page inside the wordpress dashboard.

Picturegrid is also widget ready! If your theme supports widgets, just go to the widget admin panel and drag the picturgrid widget where you want it. Note! Picturegrid widget makes use of the default options!

picturegrid_options.JPG

To Do

  • Currently limited to 500 photos. I will implement a page system, so you can choose how many photos per page (up to 500) and how many pages. This is lowest priority - picturegrid was supposed to be simple!
  • Allow users to overide defaults. For example, you could force picturegrid to show 3 images in your sidebar but 500 in your gallery page.
  • Allow random photos why stick to recent? Random would be more fun especially for sidebars.
  • Fix annoying CSS bug in wordpress which creates a gap beween rows of photos. Grrr.
  • Give widget its own set and photo limit options.
  • Thumbnail sizes for images.

Download

Old Version 0.9
Picturegrid Wordpress Plugin 1.0

Installation

  1. Upload - Upload picturegrid directory to plugins folder. This should contain the phpflickr folder and the picturegrid.php file.
  2. Activate Plugin
  3. Get and install lightbox plugin if required.
  4. Options-> Picturegrid - You’ll need to flll these out or they may be trouble!
  5. Use Widget - Drag the widget where you want it if your theme supports widgets (still uses default options).
  6. Use PHP function picturegrid(); - anywhere you’d like to insert a picturegrid. I have provided a sample template for you to upload to your theme directory. Write a new page and choose Picturegrid as your template to see it in action.
  7. Look good.

Notes

You absolutely must have a flickr API key. They are free, easy to get and lovely and reusable. Options page contains a link to the sign up page if you don’t already have one.

Updates

blue feed icon Subscribe to this feed for plugin updates

43 Comments »

RSS feed for comments on this post. TrackBack URI

  1. Mike Hedge wrote:

    ok….. so I installed it… entered my ID do I need to get a Flickr API key?

  2. Kieran wrote:

    Mike, yes, unfortunately to make us of the API flickr provide, you have to use an API key.

    They are free and sign up takes seconds.

  3. Mike wrote:

    Awesome plugin, thanks! I got mine up and running in under a half hour.
    Here it is: http://www.grandcaribbeancruise.com/about/

  4. MacBros wrote:

    Any Idea when you can expect the random option included?

  5. Kieran wrote:

    MacBros:

    Probably in the next week or two actually.

  6. Jim wrote:

    Hello,
    Awesome plugin, but a weird problem. Seems like any widget I put after yours, seems to get weirdly formatted, which makes me think maybe there’s an open tag someplace. Anyone have similar problems or solutions?

    Freakin wordpress with every part of the page spread over 9 different files I can never figure out how to fix stuff like this… Makes you miss old html… :)

  7. MacBros wrote:

    That would be great! Looking forward to it. I’ll keep checking unless the plugin will prompt me to upgrade in the WP Plugin panel.

    Thanks

  8. Kieran wrote:

    MacBros - it should now that I’ve uploaded it (and will continue to update it) on the plugin repository at wordpress.org

    Jim - I will triple check but I’m almost certain the plugin is div’d correctly. I’ll let you know if i find anything out. All brackets are closed, but the plugin widget is not in a list due to the nature of the content. - Edit seems you fixed it already?

  9. Depo wrote:

    Hi, I’ve uploaded the plugin, activated it and filled out the options.

    Now, how to add ?? And what template do u mean ?

    Depo

  10. Kieran wrote:

    Depo:
    Wordpress Pages

    If you are sill unsure what a page/template is, perhaps you could make use of the widget?

  11. Daniel wrote:

    Love the plugin - exactly what I have been looking for. One feature request (or if there is a way to hack it in the meantime I would love to know). I would love to be able to specify the size of the thumbnails that appear–either in the sidebar or when embedding in a post. I find them a bit big and would love to be able to make them much smaller if possible.

    Again. Thanks for all of your work on this plugin. Love it!

  12. Kieran wrote:

    Daniel,

    Thats not a bad idea. The thumbnails are straight from flickr - we could use css to make those smaller, but they’d still be the same file size…

  13. Kieran wrote:

    As a temp fix you can add this to your css:

    #picturegrid img {
    width: 20px;
    height: 20px;
    }

    That makes all images in the picturegrid smaller.

  14. nascent wrote:

    Just the plugin I was looking for. I’ll definitely be back for the randomised version as soon as it’s available.

    Would it also be possible to allow different pages to display random images from different sets?

  15. Kieran wrote:

    nascent
    I’m working on allowing you to pass variables when calling the ‘grid, much like this:

    < ?php picturegrid(size, type, border); ?>

    That way you can have as many picturegrids across your site as you want, with different setups.

  16. Sam wrote:

    Thanks for the plugin. I installed and used sidebar. Then I only see error message saying “Warning: Invalid argument supplied for foreach() in /home/s/sanghyuk/public_html/wp/wp-content/plugins/picturegrid/picturegrid.php on line 217″. What did I do wrong?

  17. nancy wrote:

    i got this error Warning: Invalid argument supplied for foreach() in /………/wp-content/plugins/picturegrid.php on line 217

  18. Patrick wrote:

    Hi there,
    thanks for the plugin, seems to work great!

    I can’t get the lightbox functionality to work, though. Having installed and activated the Slimbox plugin, Picturegrid adds rel=’lightbox[]’ to every picture, but the Box doesn’t show up (clicking a picture just opens the medium version of it on Flickr). Any ideas?

  19. Kieran wrote:

    Patrick - the issue is your lightbox plugin. If you wait for all the thumbnails to load the lightbox works just fine. If you click before they have finished then the script is not active.

    Perhaps try another plugin? This is a well documented issue.

    Sam/Nancy - Your API keys are probably incorrect.

  20. joe wrote:

    Looks like exactly what I am looking for only I’m getting a problem on install … when I go to activate the plugin - the cell where the description of this plugin should be in my plugin mgmt screen is full of the picture grid php code… I’m pretty sure I have the files uploaded correctly.

    /wordpress/wp-content/plugins/picturegrid/picturegrid.php

    any guesses?

  21. Calidro wrote:

    Patrick: I do not know if you are using another lightbox type of script, (you wrote Slimbox)in my case I´m using the lightview, so I did change in the script the code around the line 214 in order to trigger the script.
    =====================
    $photo_thumbs .= “buildPhotoURL($photo, “Medium”) . “‘ class=’lightview[]’ title=’” . $photo[’title’] . “‘ alt=”>buildPhotoURL($photo, “Square”) . “‘ title=’” . $photo[’title’] . “‘ alt=”/>“;
    ================
    note I change just rel for class and instead of lightbox I used lightview.
    Hope this can help.
    Regards

  22. Brian wrote:

    Looking forward to both of these on the ‘To Do’ list:

    1. Allow users to overide defaults. For example, you could force picturegrid to show 3 images in your sidebar but 500 in your gallery page.
    2. Allow random photos why stick to recent? Random would be more fun especially for sidebars.

    Keep up the great work!

  23. collin peterson wrote:

    I get the following error in Firefox, but not in IE…

    Warning: Invalid argument supplied for foreach()…wp-content/plugins/picturegrid/picturegrid.php on line 213

    This is very frustrating… IE pulls of the thumbnails perfectly, firefox gives me this error.

  24. Kieran wrote:

    Colin -

    That error is a php error which is executed by your server and has nothing to do with the browser you are using.

  25. The House of Husar wrote:

    Any news on the random feature. Also, any chance of making the plugin display larger than the square thumb? I would like the small or medium size photo to be displayed.

    Cheers.

  26. Kieran wrote:

    Random feature will be available in the next version, though this plugin has been parked momentarily. Development will resume soon.

    And no, its square thumbs only I’m afraid. Thats essentially the purpose of the plugin….

  27. Joel wrote:

    Has anyone come across the grid’s images linking to farm3.static.flickr…..? I looked through the php, and of course it was correct so I’m wondering if it might be an issue with the api key flickr gave me. Any ideas would be welcome; I’m going to try to figure this out…

    There’s an example (of the wrong links) on my blog (linked from my name).

    cheers.

  28. Joel wrote:

    Sorry to be posting again. Figured it out. With the lightbox feature turned on and using slimbox it links it (understandably) to the actual image. and if the lightbox plugin doesn’t work it just shoots over there. so. problem solved. and a big “doh” from me.

  29. Gray wrote:

    I am having the same problem as Joe, above, and I have tried uploading every possible folder of picturegrid in various combinations into my plugins directory, yet I still get the php code in my plugins directory instead of a plugin. Any idea what’s going on?

  30. Kieran wrote:

    Joel/Gray

    There is a problem with Unix linebreaks. Click “edit plugin” immediately save the file and refresh the plugins page which should convert the linebreaks.

    Either that or quickly check the solutions in the simplepie FAQ

  31. Mike Hedge wrote:

    love this… any way to use two different sets on two different pages or my wordpress site?

  32. Joe wrote:

    I have got it working in the widget fine but i’d like it on a page - and i’m struggling i have placed both: picturegrid(); and but nothing seems to be working can you please advise.

  33. Kieran wrote:

    Joe,

    Make sure you are putting the function inside PHP tags - the plugin is definately working if the widget is, as the widget just takes the function and puts it in the right place in the sidebar.

    Mike,

    Coming soon…. not yet.

  34. Mike Hedge wrote:

    …… is there some hack where I can rename one install of picturegrid something like picturegrid2.exe, then install it again….

    here is my page http://www.mikehedge.com/jumping

    genius! I want to do the same thing with my bio page so people can see all photos in a set I have that’s all about me…..

    Mike

  35. kPod wrote:

    I found my problem. I cannot call a Picturegrid inside an entry. I /have/ to call it via a template.

  36. links for 2008-04-10 at nyc.locationscout.us wrote:

    […] kierandelaney.net » Picturegrid Wordpress Plugin (tags: wordpress flickr plugins) […]

  37. Joel G Goodman » Plugin: wp-picturegrid wrote:

    […] Coulter, who’s our db admin here at GC). phpflickr is sweet. And the plugin I use is called wp-picturegrid created by Kieran […]

  38. coffee wrote:

    Awesome plugin! It makes my site look so much better. :) Like others, waiting for the random feature!!

    I have enabled the side bar widget and by default it is called at Picture Grid (linking to this site) Is there a way by which I can name it somethign else ?

  39. logicalnot wrote:

    I love the idea — but i don’t have (and don’t want to have) a flickr account.

    So, as a wish/suggestion, will it be possible to give the plugin a specific folder url (full of jpeg) and get the same results? — assuming that the plugin will make all the needed thumbnails and order them either by name or creation date.

    Thank you!
    Have a nice and keep up the good work!

  40. Kieran wrote:

    Coffee: I plan to include widget title options in the next release. Thanks for the support.

    Logicalnot: Thats really beyond the scope of this plugin - its made entirely for use with Flickr. Flickr provides the images, the thumbnails and the set structure for the plugin and without this the plugin would essentially be completely different underneath!

  41. Jay wrote:

    Love this plugin, it has replaced FlickrRSS.

    Just a few things, do you plan on adding support to have it’s own title above it? I would love it if I could have it say Flickr up top.

    Can’t wait for the random image feature, that would be great.

  42. Davide Benini wrote:

    Hello Kieran, bug report… Here’s how my plugin activation page looks like after putting the picturegrid folder into wp-content/plugin:

    http://img.skitch.com/20080501-cwnmmmj4asfdc8rjt156kb2fqw.jpg

    This looks like a bug to me, but there might be something wrong with my setup. I use WP 2.5 with a number of plugins, but I have deactivated them all to debug, so it looks like it’s not any other plugin’s fault.

    Any suggestion?

    Davide

  43. Davide Benini wrote:

    The plugin seems to inject css through a “style” tag inside the body; as a consequence, my page doesn’t validate. I think the code style code should be injected into the head section, through the wp_head hook. Are you planning to modify this behaviour? I could implement the change myself, but I don’t want to disrupt future compatibility.
    Thanks for the great job,
    Davide

    PS: disregard the previous report, re.reading the comments I have found out the problem were mac OS line endings.

Leave a comment

XHTML: <a href="" title=""> <abbr title=""> <acronym title=""> <b> <blockquote cite=""> <cite> <code> <del datetime=""> <em> <i> <q cite=""> <strike> <strong>

Powered by WordPress with GimpStyle Theme heavily modified by Kieran Delaney.
Entries and comments feeds. Valid XHTML and CSS. 11,836 spam comments ignored.