Recent Photos Plugin for WordPress

// February 28th, 2010 // Plugins, Wordpress

Recent Photos Plugin: can be used to display recent photos from your media library in the sidebar.

Updates: Version 0.0.2 – Added option to randomize photos

Detailed Description:
Recent Photos Plugin provides with a widget to display n numbers of photos in the sidebar.
The display can be customized through custom css or integrated in main style sheet file of your theme. Plugin also provides an option to use Thickbox (along with the patch code necessary for running thickbox on wordpress).

Download: Recent Photos Plugin.

Demosites:

  1. Demo with Default WP Theme
  2. This website shows the use of this plugin customised by css.

Installation:

  • Plugin folder in the WordPress plugins folder must be `recent-photos`
  • Upload folder `recent-photos` to the `/wp-content/plugins/` directory
  • Activate the plugin through the ‘Plugins’ menu in WordPress
  • Go to WP Admin > Appereance > Widgets and put the ‘Recent Photos’ widget in your sidebar
  • Configure the options as per your requirements and wordpress installation

Upgrade Instructions

  • Just Click ‘Upgrade Plugin Automatically’ within the WordPress Plugin Admin Area
  • Go to WP Admin > Appereance > Widgets and put the ‘Recent Photos’ widget in your sidebar
  • Configure the options as per your requirements and wordpress installation (New option for Randomize should be there)

Configuration Options:

  • Title: Title for the widget will be displayed as per your theme
  • Number of the photos: Number of photos that will be displayed in the sidebar
  • Randomize: Check to display photos in random
  • Browse Photo Link: Full link to your photos/gallery page
    Leave blank if you don’t want to show the link.
  • Use Thickbox: Enables/Disables the use of thickbox for this widget
  • WordPress Path: Applicable only if Thickbox is enabled
    This option is necessary to provide the patch for thickbox to correctly display thickbox related images (loadinganimation and close). If your wordpress installation is in a subdirectory provide the path for the same followed by a forward slash
    Eg. wordpress/ When the WP installation is in ‘wordpress’ subdirectory
  • Use Custom CSS: Enable/Disables the use of Custom CSS
  • Custom CSS: For styling this plugin requires following CSS ids and classes to be defined
    #recent_photos_envelope{margin:0 0 30px 0;}
    .recent_photo_image a {float:left;display:inline;margin:0 16px 15px 0;border:1px dashed #888;padding:5px}
    .recent_photo_image a:hover {border:1px dashed #000}
    

    The above css code is default css provided with the plugin

Frequently Asked Questions
Q. How to integrate css code in your default style sheet?
A. Copy the default css code into your style sheet
#recent_photos_envelope{margin:0 0 20px 0;}
.recent_photo_image a {float:left;display:inline;margin:0 16px 15px 0;border:1px dashed #888;padding:5px}
.recent_photo_image a:hover {border:1px dashed #000}
#browsephotos{margin: 0 25px 10px 12px; float:right;}

Enable Use Custom CSS option in the widget admin
Make sure Custom CSS code textarea is blank (Should contain no spaces also)

16 Responses to “Recent Photos Plugin for WordPress”

  1. Sascha says:

    Hi, nice plugin… It’s nearly exactly what I need. Would it be possible to display additional images that are attached via thumbnail or custom fields? Maybe an additional config-field to define a custom field with an image in every post? I would be happy to support the development financially! ;)
    Do you think this is possible?

    Regards Sascha

  2. Hi,

    I loved the plugin. Very simple and clean. My only problem is the loading and close button does not show. I’m mac base and use firefox and safari. It doesn’t show anything in firefox at all and in Safari, it shows that the image file is missing. I deleted the plugin and installed it again but it doesn’t do anything. I check the files and they are all there. Don’t know what to do..thanks in advance.

    Mike

  3. Annmarie Kostyk says:

    LOVE this plug in! Question…For some reason this widget is blending in with my Recent Post widget. Any way to fix that that’s not too technical. I’m not very computer savvy.

    The photos are eye candy! Literally!

  4. Johanna says:

    I adore this plugin, and I only had a simple question. I tried everything I could to get the area the photos are in to center, and I couldn’t figure out how. I eventually found a work around, but I don’t remember what I used and I am running a new install of WordPress. Is there a simple way to do this?

    • instruite says:

      Hi Johanna,
      I am assuming that you want to put the recent photos to appear in the center of the sidebar on the you Johanna’s Place blog and from what I can see on your site I think you are using the custom css part of the plugin too. To get the photos in the center you need to add left margin to the recent_photos_envelope div.
      Your present css code is

      #recent_photos_envelope{margin:0 0 10px;}

      change it to

      #recent_photos_envelope{margin:0 0 10px 20px;}

      You can change with that 20px value to get the alignment you want.

      Thanks.

  5. mark says:

    I don;t want every image I upload to the library to be available to the plugin. How do I separate them?

    see – http://www.tentcity4.info and look at the recent photos sidebar – it contains an image I uploaded to represent an available PDF download in the latest post.

    Thanks!

    Mark

    • instruite says:

      Hi Mark,
      With present plugin code its not possible to exclude certain images.
      After having a look at your site, I have an idea how you can do it on your site but it requires little code tweaking.


      Go to WordPress Admin Dashboard -> Plugin -> Editor
      Select 'Recent Photos' in the Dropdown box for 'Select plugin to edit' and Click 'Select'
      Search for "post_mime_type"=>"image/jpeg,image/gif,image/jpg,image/png"
      Replace it with "post_mime_type"=>"image/jpeg,image/jpg,image/png"

      This will remove the pdf icon from your sidebar but in future if you add any gif format image that will be excluded too.
      I will see if it can be implemented in any easy way in future release but it may take time.

      Thanks,
      instruite

  6. Peter4 says:

    Hello: Thanks for the new version – it is excellent!

    One thing though, is it possible to randomize the ‘folder’? If you look at the site in question (www.pearlstreetchildcare.com.au) we want to show 6 images in the sidebar, but have these 6 images randomly selected from the folder/page where the images were added. How is this possible?

    • instruite says:

      Hi Peter,
      Glad you liked the new version.
      Regarding your query, I am not sure I get it fully what you are looking for. Because when I saw the site you mentioned there is only 1 page where all the photos were added.

  7. Peter4 says:

    Hello, I have configured your plugin to show only 6 images out of 30+. The problem is I want to randomise the 6 that show each time the page loads…how do I do this??? Thanks

    • instruite says:

      Hi Peter,
      Present Plugin does not have option for randomly displaying the images.
      I will add your query as a feature request to To-Do of this plugin and try to implement it in future release.

      Thanks

    • instruite says:

      Hi Peter,
      Just upgrade the plugin to 0.0.2 version and you should see the option for Randomizing the photos in the widget configuration panel.

      Thanks.

Leave a Reply