Tony Rockwell – Info

sharepoinTony@info – Cloud Computing adventures

Archive for April, 2010

Using thumbnails in SharePoint 2007

Posted by sharepoinTony on April 28, 2010

Have you ever needed to display the thumbnail of an image in one of your picture libraries?

Don’t want to resize the image and store the smaller image in the library?

SharePoint creates thumbnails of every image you upload into a picture library – you can see this by looking at your library.  Notice that when you look at the default “All Documents” view there is a Thumbnail column displaying your image!

This post shows you how you can make use of these SharePoint generated thumbnails, should you need thumbnail versions somewhere in your site.  First we need to get on the same page regarding the location of those thumbnails.   They are stored in a subdirectory named “_t” which resides beneath your library.

Consider that the path to one of your images in your library is: http://www.yoursite.com/site/PictureLibrary/cool_image.gif

The thumbnail for that specific image will be found here: http://www.yoursite.com/site/PictureLibrary/_t/

The image name is changed too, so don’t go jumping away from this blog post to try this just yet!

The pattern used for renaming your images is as follows:

  1. Replace the last period in the filename with underscores
  2. Append a “.jpg” to the end of the filename

In our example above the thumbnail would be: http://www.yoursite.com/site/PictureLibrary/_t/cool_image_gif.jpg

Yes, all thumbnail images – regardless of they file type the original was, are jpg files.

Ok, now you can run off and try this.

Posted in SharePoint 2007 | Tagged: , | 2 Comments »