This plugin hasn’t been tested with the latest 3 major releases of WordPress. It may no longer be maintained or supported and may have compatibility issues when used with more recent versions of WordPress.

Tui’s Find Thumb


Many WordPress themes, are heavily dependant on “feature images” to use as thumbnails to make them look good. This is great except it adds a lot of extra work setting up these thumb references, but equally if you are in a hurry and forget you add the thumb then the look of the theme breaks.

So here is Tui’s Find Thumb plugin. It is very easy to use. It’s purpose is to replace the Image function currently used in your theme with one that is lot more clever. With these new functions available you can do everything from a randomly select an image, or return a URL or IMG tag source specifically for that post.

The post option works through this logic until it gets a result

  1. Returns an IMG tag based on the thumbnail set in the post meta data (through special post fields)
  2. The first image in the post
  3. A randomly chosen image from a directory (in your base images directory) with the same name as the posts first category slug.
  4. A randomly chosen image from your base images directory

Functions available

There are 5 funtions that can be accessed through this plugin.

1. tui_findRandomBackgroundSTYLE()

Returns a random image URL from the background images folder if one exists else the base image folder.

2, tui_findRandomThumbURL()

Returns a random image URL from base image folder

3. tui_findRandomThumbIMG(“Height”,”Width”,”Class”,”Title”,”Alt”)

Returns a random image IMG Tage from base image folder

4. tui_findPostThumbURL(“thepostID”)

Returns a URL, having searched based on the postID

5. tui_findPostThumbIMG(“thepostID”,”Height”,”Width”,”Class”,”Title”,”Alt”)

Returns an IMG tag, containing the URL, height, width, alt, title and class, having searched based on the postID<h3>Support</h3>

Support can be found on plugin homepage:

You can also view project here:

  • Additional documentation:

  • Issues & requests:

  • Development version:

  • Change logs:


  • Sample of a theme using a thumbnail image.
  • Download then activate the plugin.
  • Goto plugin settings page.
  • Set up the base directory for your images.
  • Set up the default css class to use and thumbnail name.
  • How should your thumbnails be scaled and what size by default.
  • If you need more help look at the top right hand corner of the options page.
  • Now it's time to edit your theme. Look for where thumbnails are used and remove code like this that was in my theme.
  • And also remove this. Obviously, be careful, have a backup and make sure you know what you are doing.
  • Replace all that with something like this. If you know the plugin will remain installed don't worry about error checking.
  • Now go find out the "slug" names for each of your categories.
  • Finally using your ftp client set up matching directories in your base image directory, up load those images you want to be random.


This section describes how to install the plugin and get it working.

  1. Vistit plugin home page to get full install instructions including image references.
  2. Upload tui_findthumb.php to the /wp-content/plugins/ directory
  3. Activate the plugin through the ‘Plugins’ menu in WordPress
  4. Edit your plugin settings
  5. Set up your image folders
  6. Edit pages in your templates


Can I contact you?

Yes. email me

I’d like to make a donation, is that possible?

That would be great and certainly would help development efforts. To do so click here thank you.

How do I report at bug?

The easiest way is to visit my Google Code Project and register an issue

Contributors & Developers

“Tui’s Find Thumb” is open source software. The following people have contributed to this plugin.

Translate “Tui’s Find Thumb” into your language.

Interested in development?

Browse the code, check out the SVN repository, or subscribe to the development log by RSS.