Many bloggers are preferring excerpts to be shown on their homepages, but the problem is that you have to explicitly give the meta data in the custom field of the wordpress editor, for displaying the images on the homepage along with the excerpts, But the problem is with old blogs, where bloggers have not mentioned the meta-data and the process of giving the path for each post, is a very lengthy process now.
Here’s how you can display the first image inside your post, in the homepage beside the excerpt more easily, using the first image within the post.
1. Download the Thumbnail for Excerpts WordPress Plugin.
2. Unpack and Upload the ‘thumbnailforexcerpts’ directory to the ‘wp-content/plugins’ directory on your WordPress plugins directory.
4. Activate plugin.
Thumbnail For Excerpts searches the post for the first image. If exists, than it will search for the thumbnail created by default by WordPress for the image, if it was uploaded from WP administration area. If not, it will show the scaled image.
You can as well customize the plugin, by editing the values in the plugin file.
- “TFE_ALIGN”,”left|right” : Image alignment
- “TFE_SIZE”,”100″ : The size of the thumbnail; if you set to 0 it will be the default size of your WP thumbnails, from admin area.
- “TFE_MAXSIZE”,”yes|no” : If yes, than the above indicated size will be used as maximum size for width and height; if no, than the above indicated size is used only to limit the width.
- “TFE_SPACE”,”5″ : HSPACE parameter of the IMG tag
- “TFE_LINK”,”yes|no” : if yes, the image will link to the post
- “TFE_CLASS”,”imgtfe” : the class for the thumbnail images; you can change it or use this class in you CSS file
- “TFE_CREATETH”,”yes|no” : if yes, the images without thumbnails will have one created now (based on default values for thumbnail from admin area, or on TFE_SIZE if in admin area thumbnail size is set to zero
- “TFE_TITLE”,”no|yes” If yes, it will use titles for pictures
You can find this plugin in action in the Homepage of this blog.