[WordPress Plugin] Automatic Post Thumbnail

This plugin now has a PRO version. Please see this for details.

Please continue all discussions regarding the free plugin in the plugin forum.

WordPress 2.9 introduced a new feature called Post Thumbnails (a.k.a Featured Thumbnails) allowing you to assign an image to your post. This image can then be easily shown in your blog using a simple function. Mark Jaquith has written an excellent blog post explaining this new feature in detail, do read it if you are wondering how to get started or why post thumbnail widget does not show up in your admin section.

The current implementation of this post thumbnails feature has a few lacunae, the foremost being you have to assign this image manually to the post. So, for your thousands of posts that you created prior to WordPress 2.9 you will end up assigning an image to every post. Also, even if you are creating a new post with just one image in it, you must assign it as a Post Thumbnail manually. Another drawback is that you cannot assign the images inserted through URL as Post Thumbnails.

This is where my new plugin and in fact my first ever WordPress plugin – Automatic Post Thumbnail – comes into play. As the name suggests, the plugin will automatically assign a thumbnail to your post when you publish it. The first image in your post is used as Post Thumbnail. This is irrespective of whether the image is an uploaded image or inserted through URL. The plugin will do whatever it needs to assign it as Post Thumbnail.

If you want some other image as Post Thumbnail instead of the first one in your post, simply assign it manually and the plugin will respect your decision.

Also, sometimes it may be that you don’t want Post Thumbnail at all for your post even if there’s an image in your post. Unfortunately, the plugin is not advanced enough to read your mind but it can read the Custom Fields added to post ;) . Add a Custom Field skip_post_thumb to your post and the plugin won’t do anything for that post.

Installation

  1. Upload directory ‘auto-post-thumbnail’ to the ‘/wp-content/plugins/’ directory
  2. Activate the plugin through the ‘Plugins’ menu in WordPress
  3. Sorry, no more steps :)

Download PRO: Click Here

Download: Click Here


Changelog:

V 3.2.1

* Added code to correctly link the featured/post thumbnail with the post so that the Media Library shows the association correctly.
* Assigning title to the generated featured/post thumbnail by extracting it from the title of processed image.

V 3.2
Added support for creating featured thumbnails for custom post types as well. Batch processing will also generate thumbnails for any type of post.

V 3.1
Renamed Gen. Post Thumbnails to Auto Post Thumbnail and moved it under Settings menu.

V 3.0
* Added Batch Processing capability to generate post thumbnails for already published posts.
* A new menu item Gen. Post Thumbnails is added under Tools menu.

V 2.0
Added functionality to generate Post Thumbnail for scheduled posts. Thumbnail will be generated when scheduled post gets published.

V 1.1
Added a wrapper function using cURL for file_get_contents in case ‘allow_url_fopen’ ini setting is off.

Feedback, suggestions, patches, bug reports most welcome.

This plugin now has a PRO version. Please see this for details.

Please continue all discussions regarding the free plugin in the plugin forum

177 Responses to [WordPress Plugin] Automatic Post Thumbnail

  1. Markus April 21, 2010 at 2:23 pm #

    Nice plugin, but how do i know that the plugin is “ready” or produces “errors”. When starts the plugin? If i try to read a post?

    Thanks for your work and time!
    M

    • Aditya Mooley April 21, 2010 at 10:04 pm #

      @Markus – Plugin will do its work only when you Publish the post.

      • Markus April 26, 2010 at 6:08 pm #

        Thanks for your answer. It is possible to inlcude a function that scan all old posts und add the thumb? It will be nice to add post_thumbs to all my old posts.

        Thanks for your work and time! M

  2. rami April 21, 2010 at 6:05 pm #

    nice plugin, but what about the images that where not added using wp-media-uploader?

    there was a time when we added an HTML code to add an image (…<img src=….). what about those posts?

    • Aditya Mooley April 21, 2010 at 10:18 pm #

      @rami – That’s the beauty of this plugin. It can make any image as Post Thumbnail. The only condition is, that image must be a valid image and the URL should be accessible.

  3. gulflee April 23, 2010 at 8:15 pm #

    i had try but the _thumbnail_id dosnt appear in mysql ??
    that means the image did not save as post_thumbnail.
    can help? thank

    • gulflee April 24, 2010 at 6:10 am #

      sorry i had manage to do it in a new install wp. but it just for the file upload to media library, the URL insert not appearing, i found the problem is the image did not upload, the file name is created but is empty 0kb. did i done anything wrong? (the first image is an url out of the wordpress

  4. Patrick Mosimann April 25, 2010 at 6:02 pm #

    Hi Aditya,

    Thanks for the great plugin. But I’ve a problem with my WP iPhone App. When upload some photos from my iPhone I get a file with the size of 0 bytes after publishing. Could be a problem with the ending of jpeg or the stupid long filename like “l_2048_1536_63278495-65F1-4296-9F88-12023524C8FB.jpeg”

    • Patrick Mosimann April 25, 2010 at 8:28 pm #

      I’ve found the mistake. The allow_url_fopen was set to off.

  5. Vincent April 26, 2010 at 5:11 am #

    Thanks!
    But what is the difference with Get The Image ?
    http://justintadlock.com/archives/2008/05/27/get-the-image-wordpress-plugin

    • Aditya Mooley May 2, 2010 at 1:27 pm #

      Well, not much different. But my plugin looks only into the post for creating post thumbnail and custom field is used to skip auto thumbnail creation.

  6. Renmei May 2, 2010 at 11:02 am #

    It works! Thank you for your plug-in. But can you fix the schedule post issue? It wont automatically detect a schedule post image unless re-published

    • Aditya Mooley May 2, 2010 at 1:47 pm #

      Sure. This will be fixed in the next release. Thanks for reporting.

  7. Gustavo Leig May 31, 2010 at 8:03 pm #

    Thanks for the plugin and all work. My server doesnt allow allow_url_fopen, so,

    any chance to that the plugin could use other resource that wouldnt need allow_url_fopen ?

    • Aditya Mooley June 16, 2010 at 3:15 pm #

      @Gustavo – I have added a functionality to fetch the photo using cURL if allow_url_fopen is disabled.

      HTH

  8. Nik June 5, 2010 at 8:05 pm #

    I’m a happy user of your plugin. Fixing the scheduled post issue would make it perfect!

  9. Lars June 7, 2010 at 1:30 pm #

    Thanks for this great plugin!

    Hope the fix for the scheduled post issue will comming soon!

    I want to use the plugin for a second blog with 1000 posts and to re-published any post to set the thumb….! ;)

    • Tarique Sani June 7, 2010 at 2:32 pm #

      Hold on Folks, Aditya is on a vacation he will be back on Thursday and you will have a new release!

    • Aditya Mooley June 18, 2010 at 10:01 am #

      Plugin is now updated to work with scheduled posts as well.

      Enjoy!

  10. Aditya Mooley June 16, 2010 at 9:33 am #

    @Nik, @Lars –
    Thanks for using the plugin and glad that you liked it.

    The plugin works well with the scheduled posts. I tested it on my dev setup. But the wordpress itself is having problem with publishing the scheduled posts.

    Here’s the long discussion on WordPress forum related to this issue -> http://wordpress.org/support/topic/343080?replies=72

  11. Gravity June 18, 2010 at 9:05 am #

    Hiya,
    I would like to batch upgrade all my 200 posts to include thumbnails. This is so I can migrate from my current text-based theme to a graphic-oriented one.
    Is there any way to do this without editing each post?

    • Aditya Mooley June 18, 2010 at 9:40 am #

      Not possible at the moment. But I will add this feature soon as lot of people are requesting for this. So stay tuned …

      • Gravity June 19, 2010 at 3:18 pm #

        Thanks. I appreciate it.

  12. Sooraj June 19, 2010 at 11:30 am #

    Hi Aditya…thanks for a terrific plugin. Would you also be able to include an automatic thumbnail for embedded videos? Currently videos don’t have thumbnails. I believe there are already plugins for this, but since I use videos only occasionally I thought it would be a good idea to combine them into this plugin. Is this possible?

  13. dikeluar.in June 20, 2010 at 8:29 pm #

    I have site with post over 5000, and i upload image via file manager. how to generate? im try to active plugin but thumbnail still not show.

    thanks

    • Aditya Mooley June 21, 2010 at 8:43 am #

      You are asking for a batch process kind of functionality which is not possible at the moment. I have plans to add this but no time frame is set at the moment.

  14. vince jelenic July 7, 2010 at 2:25 pm #

    Hi,
    Great plugin. I never did like the “set thumbnail” setup on wordpress 2.9x… just found it awkward.
    This solves that issue briliantly, I just do my post and forget about the thumbnail, and there it is !

    but….
    We ran into slight problem.
    I have 1000 posts, using URL image mostly, NOT in wordpress, on our other server.

    your plugin has a preg_match_all filter which misses any URL’s without quotation marks as in URL=”myimage.jpg” works. but URL=myimage.jpg does not.

    I added the following more general filter., as you see your original is commented out here

    // Get all images from post's body
    $pattern = '/]+src[\\s=\'"]';
    $pattern .= '+([^"\'>\\s]+)/is';

    preg_match_all($pattern, $post[0]->post_content, $matches);
    /* preg_match_all('/]*src\s*=\s*["\']?([^"\'>]*)/i', $post[0]->post_content, $matches); */

    With this small change, works like a charm, and picks up first image in post. All I need do is “update” an old post, or make a new one without thinking about it anymore.

    Thanks for an amazingly useful plugin… now I just have to figure out a way to “update” 1000 posts quickly, but even then, this plugin will cut that time much shorter and work into future with our image urls.
    great stuff.

    Vince.

    • Aditya Mooley July 7, 2010 at 3:12 pm #

      Thanks for your feedback and the code to improve the plugin functionality. But the code your provided isn’t working for me.

      I tested it with a random image from flickr. Even the URL’s with quotation marks around failed to filter through the new pattern. May be you missed something while pasting the code here!

  15. vince jelenic July 11, 2010 at 3:54 am #

    Hi Aditya, sorry about that.

    here’s the code i’m using now.

    // Get all images from post's body

    $pattern = '/]+src[\\s=\'"]';
    $pattern .= '+([^"\'>\\s]+)/is';
    preg_match_all($pattern,$post[0]->post_content, $matches);

    /* preg_match_all('/]*src\s*=\s*[\""\']?([^\""\'>]*)/i', $post[0]->post_content, $matches); */

    The commented out preg_match is the original.
    I found this to work great on our site, using now.

    So far as the updating of all older posts to use the new post thumbnails, again, your plugin came to the rescue.

    I did the following, I commented out the check for a post thumbnail… and allowed your plugin to generate one as needed.

    Thus.

    * Look for this id in the IMG tag.
    */
    /* preg_match('/wp-image-([\d]*)/i', $image, $thumb_id);
    $thumb_id = $thumb_id[1];*/

    // Ok. No id found. Some other way used to insert the image in post. Fetch the image from URL and do the needful.
    if (!$thumb_id) {

    By commenting this out, I was able to just show 50 posts on an edit page, bulk select all, and hit the “update”.
    All posts now carried a thumbnail,

    I found if I left this live… it created the situation of attempting to create a thumbnail, being sometimes unsuccessful, and it would not REMOVE the not working thumbnail.
    my commenting it out allowed it to roll over all posts and update the thumbnails successfully for all posts with images. in the content.

    Once the website is fully caught up i’ll just uncomment that line and we’re back up to speed.

    Hope that works for you. .
    If you prefer, I have no issue with emailing you a zipped version of the one i’m using live now.

    caveat: I use wp 2.92 at this time.

    I have tested with wp 3.0, but not extensively, (on twenty-ten, qualifire, and sliding-door themes). I have not tested the bulk update method on 3.0 yet.

  16. vince jelenic July 11, 2010 at 4:01 am #

    darn, I forgot… there is a small glitch somewhere in thumbnail handling… seems if one exists your plugin can’t create one, but if you view, say 50 posts in edit window…. your plugin tries to create thumbnails automatically if you have thumbnails showing in your admin theme.

    So… it hangs.

    here’s the change I found worked in your script.

    // If we succeed in generating thumg, let's update post meta
    if ($thumb_id) {
    update_post_meta( $post_id, '_thumbnail_id', $thumb_id );
    sleep(1);
    update_post_meta( $post_id, '_thumbnail_id', $thumb_id );
    break;

    It seems by forcing a delay of 1 second , and having your plugin update the meta data again.. it catches the NEW thumbnail just created.

    This puzzled me for a bit… not sure if this is correct programming.. but I needed a brute-force solution quick, so went this route. perhaps a dirty solution, but it solved it quick.

    cheers.

  17. ray July 14, 2010 at 10:31 pm #

    Dumb question, does this plugin add a custom field for “thumbnail” in the post with the image location? And will it pull thumbnails for posts that are auto pulled (ie feedwordpress) by RSS?

    Curious on how this integrates with a standard them that utilizes the Thumbnail custom field for its front page.

    thanks!

    • Aditya Mooley July 15, 2010 at 8:39 am #

      I am populating a built in post meta data for post thumbnail. This feature was added in WordPress 2.9. I doubt whether older themes and the RSS are making use of this meta data. But you can always modify your theme to utilize this post thumbnail.
      Read this post on how to achieve that.

  18. Batman Arkham City August 9, 2010 at 12:57 am #

    Cool plugin, which is working for me in its basic state, though I’m having three issues.

    1) The full size image still shows up on my front page. For instance if I want to put a 600×400 image at the top of my article, when I post it, on the front page it will show the thumbnail (good), with the full size image right next to it (bad). How can I remove the full size image from the front page while keeping the teaser text?

    2) A linebreak is being inserted after the thumbnail on the front page, rather than the text wrapping around the thumbnail, which I would prefer. I can’t find where to change this in the code.

    3) Is there a way to make the thumbnail a clickable link that links to the full article, like the title does?

    Thanks!

    • Aditya Mooley August 9, 2010 at 10:50 am #

      @Batman

      All the issues you have mentioned are more likely with your theme rather than the plugin. This plugin just works on admin side and doesn’t interfere in the display of posts.

      So, for things like, linebreaks and link on thumbnail image, you will have to adjust your theme code.

      BTW, nice to see that Batman is using my plugin. ;)

      • Batman Arkham City August 13, 2010 at 8:04 am #

        Hi Aditya,

        I was able to solve #1 and #2 that I posted above by editing my theme, but I cannot figure out #3 for the life of me. Can you offer any guidance on where I would even start? I don’t have a normal object to add the link around. Should I be editing the files in the plugin to do it?

  19. Lynda August 9, 2010 at 3:27 am #

    This plugin recently stopped working for me. I updated to WP 3.0 and changed my WP directory to be a sub-directory of my blog on the same day. After that this plugin no longer worked, so I’m not sure which of the two is the cause.

    • Aditya Mooley August 9, 2010 at 8:31 am #

      Try to re-enable the plugin and see if it gives any errors. Might be a permission issue and if so, you will see the error message when you enable the plugin again.

      • Lynda August 10, 2010 at 9:53 pm #

        Oh, interesting idea, but that didn’t work and I got no errors. It THINKS it’s working (it thinks there’s an image there which isn’t). Strangely – the images that were there before (when it was working) are not there now. If I clicke “Remove Featured Image” and update, then it will again think it’s attaching a thumbnail that isn’t there.

        I have all relevant folders writable and I actually didn’t move my WP files at all; they were always in the subdirectory they’re in now; it’s the blog I moved.

        Is anyone else able to use this with 3.0?

  20. Chris August 10, 2010 at 4:56 am #

    I have installed and activated the plug but nothing happened. Is there something more I need to do?

    • Tarique Sani August 10, 2010 at 5:40 pm #

      You need to have a picture in your post and then publish the post, Also your theme should be “Post Thumbnail” aware for you to see it

  21. Halo Reach August 10, 2010 at 8:08 pm #

    Is it possible to make it automatically link the thumbnail to the URL of the article it came from?

    • Tarique Sani August 10, 2010 at 8:30 pm #

      Please see http://codex.wordpress.org/Post_Thumbnails to understand the topic of Post Thumbnails.

    • Lynda August 10, 2010 at 9:54 pm #

      Halo, there’s a plugin called Get The Image which is pretty easy to use, very robust and will do exactly that. You need to be comfortable editing your templates though.

  22. vince jelenic August 10, 2010 at 8:39 pm #

    Hi, just popped in to say
    THANK YOU, this plugin worked miracles for me.

    As per my previous note, I modified a few lines so that it picks up and inserts thumbnails on every post, with a couple of fixes for the matching scheme, works for me.

    Now I can publish a post, and it’s all automatic, thumbnail in, and resized.

    BUT>>>>>>>
    I just built a little importer for my blog…. and proceeded to import about 1000 posts. This importer either creates or updates current posts.

    The result was better than expected.
    In the IMPORTER, I do NOT set the thumbnail, but let your Auto Post thumbnail plugin handle that.

    Guess what… when the posts are published or updated, your plugin inserts the post thumbnail automatically with no intervention on my part at all.

    it’s almost like it’s fully autoMAGIC now…
    thanks, my blog/website is now almost like a full CMS system now.

    cheers.

  23. George Darkow August 11, 2010 at 9:03 pm #

    I have a strange issue. I’m using Auto Post Thumbnail on my WPMU site. The plugin works great…. but only on SOME of the blogs.

    My site takes 25 or so blogs and via Sitewide Tags, places them all on a “main index” page. On about half of the blogs, the plugin takes the thumbnail and assigns it as the “featured image” the way it should. On the other half, a meta is created called “thumbnail” and a URL is assigned, but nothing is set for the featured image.

    I’m at a complete loss as to why this is the case on HALF of the blogs, and not a universal issues.

    Any help would be ridiculously appreciated…

  24. Batman Arkham City August 14, 2010 at 1:01 am #

    Hi Aditya,

    I posted this up above but I’m not sure you saw it all buried in a reply thread.

    I was able to solve most of my issues by editing my theme, but I cannot figure out one of them for the life of me.

    I would like the thumbnail to be a clickable link to the full article, just like the title is. Normally I could use the permalink function in wordpress to wrap the object in my theme. However, since these thumbnails are being generated on the fly they’re not really even referenced anywhere in my theme layout files, so where can I add the permalink to them?

    Thanks for any insight you may have.

    • vince jelenic August 14, 2010 at 2:12 am #

      Hi, Batman. still struggling?

      to get your theme to support thumbnails, use the following in your functions.php file

      if ( function_exists( ‘add_theme_support’ ) ) {
      add_theme_support( ‘post-thumbnails’ );
      set_post_thumbnail_size( 80, 80, true );
      set_post_thumbnail_size( 50, 50, true ); // Normal post thumbnails
      add_image_size( ‘single-post-thumbnail-270′, 270, 9999 ); // Permalink thumbnail size

      I added this thumnail size of 270 because it fits well with my them.. you can modify for your use.

      I use this in the theme page where I wish to place the thumbnail.

      In your them page, inside a loop you put

      if(has_post_thumbnail()) {
      the_post_thumbnail(‘single-post-thumbnail-270′) ;

      (I’m on WP 2.92, but it worked in 3.0 too)

      HTH..
      vince.

  25. Scott August 17, 2010 at 3:41 am #

    Similar situation to others. 5,500+ posts on a photography site that all need thumbnails. Would love to know when this functionality is in place.

    Great concept and plugin. Thanks for your work.

  26. vince jelenic August 17, 2010 at 12:26 pm #

    When working properly, there should be no issue with updating thousands of posts with thumbnails. You set your screen options to show 300 posts at a time. Then select ALL, hit “edit”, and just hit update… does that not insert all the thumbnails in one swoop?

    I too experienced a few glitches, and made some changes to the plugin. and found I made a couple of small changes, and it now works great on wp 2.92 and 3.01.

    Please view the results at
    http://twojjs.com/x/1u26
    or
    http://greenspotantiques.com/wp/auto-post-thumbnail-changes-hope-it-works-for-you

    The changes I made are clearly marked with
    /* *************** Vince

    For ME, the preg_match change helped with capturing all image URLs for inclusion. Arditya indicated it did not work for him,though.

    for ME , the sleep and duplicate update seemed to solve the issue of some thumbnails not updating (or looking like they had updated but with a “ghost” image, not really there).

    Feel free to use as you require. For me, it solved the issue simply and now I don’t even think of thumbnails at all, it’s all automatic. And as I noted above, it even seem to work with importers doing 500 posts at a time.

    I have placed a copy at
    REMOVED LINK on Vince’s request
    for you to download if you wish — it is the current working copy I USE now,

    Hope that helps.
    If this solves any issues for you, please let the creator know, perhaps these minor changes will be added to the plugin itself later.
    If it doesn’t work for youl, let ME know, and i’ll take down the info since that would mean it doesn’t help.

    cheers.

    vince

    cheers.

    • Tarique Sani August 17, 2010 at 1:14 pm #

      Hi Vince – tried your plugin – did not return anything for me – sorry!

      • vince jelenic August 17, 2010 at 10:12 pm #

        Ok, Tarique, if a no go.. can we do the following? please?

        can you delete the section of my previous message above where I indicate the downloaded zip file available?

        If not working for others, it only adds to confusion. sorry about that.

        And thanks for the plugin, very handy on this end. Hope you get the batching of past posts worked out soon for others.
        cheers.

        (and a special apology to Aditya , I’m afraid I mispelt your name in an earlier note :-(

  27. Aditya Mooley August 17, 2010 at 1:48 pm #

    Since lot of users are asking for better functionality of adding post thumbnails to existing published posts, I have started work on adding this feature.

    Will keep you guys updated of the progress.

    Thanks for your interest.

    Aditya

  28. amanda August 18, 2010 at 7:24 pm #

    Hi Aditya,

    It looks like your plugin is just what i’m looking for and I’m glad to see you actually are available for help with it!

    I installed it and activated it onto my site, I published a new post and it’s not working–is there anything special that I have to do to make it work.

    I’m using Amazon Autoposter for my posts and I actually went to a scheduled post and published it manually and I don’t get the thumbnail on the home page like I want.
    I’m using Gazette theme.

    Thanks, I can give you url if you need it.

  29. Aditya Mooley August 20, 2010 at 11:59 am #

    All,

    A new version 3.0 of this plugin is now available with batch processing capability to add thumbnails for previously published posts.

    Hope this will save a great amount of time for all the users of this plugin.

    Aditya

    • Scott August 20, 2010 at 11:10 pm #

      I truly, truly appreciate that you’ve gone through the trouble to implement this. Thank you for putting in this feature

      I have a slight problem which I could imagine others might have: I use Yet Another Photoblog as the interface through which I manage my photos. As such, it doesn’t store the files as attachments nor embed img tags within the body post; instead, it references an outside table which links back via the post_id. The schema for the table is as follows:

      id (auto-generate)
      post_id (ref back to post id in wp)
      uri (format: /image. For example, /wp-content/uploads/2010/08/12011.jpg

      Before I go off and completely screw up your code with a tweak to pick up this data, is it apparent to you what needs to happen here?

      Any advice would be greatly, greatly appreciated.

      The site (subdomain) on which I’m trying to get this to work is http://models.ipanemic.com/

      Thanks again!

      • Scott August 21, 2010 at 8:50 am #

        :)

        Nevermind. Got it. Building thumbnails now. Thank you, thank you for this utility. Perfect.

  30. marta August 20, 2010 at 3:17 pm #

    hi, great plugin but i am having trouble to make it works.
    i just installed and activated and it seems all fine except that the thumbnail image on my first post using this plugin is not showing. if you have a look to my blog http://www.weloveveneto.com you will see that all previous posts, using a different widget, works fine but not my first one. does it take a while to upload it or is there any widgets that might cause some conflicts? thanks for your help
    marta

    • Aditya Mooley August 23, 2010 at 9:03 am #

      @marta – You can check whether thumbnail was generated or not, from the edit post page. The Featured Image section should show the thumbnail if its generated.

  31. Lars August 20, 2010 at 7:54 pm #

    Aditya, you are my hero of the day!! This update was just in time for me! Thx!

    I have test it on our beta webpage (release next week). It works fine with 1000 postings! You can see the results at http://beta.schnappaholic.de

    Thanks!

  32. dealtack September 11, 2010 at 11:03 pm #

    Hi, is there a way to modify it not to show the same image twice?

    now it shows the original image and the thumbnail..

    How can i set it up to see only the thumbnail?

    Thanks

    • Aditya Mooley September 20, 2010 at 11:14 am #

      @dealtack – The plugin has nothing to do with this issue. Check your template file where the post is displayed. It must be showing the thumbnail using function the_post_thumbnail();
      This function is generally used only on the listing page and not on the actual post page.

  33. Sahas Katta September 21, 2010 at 2:23 am #

    Aditya,
    You just saved me hours and hours of work. Thank you very much for putting this together. I’ll be running this on our servers before Skatter Tech 3.0 gets launched!

    Thanks!

    • Aditya Mooley September 21, 2010 at 10:29 am #

      Hey Sahas,

      Nice to know that the plugin was helpful for you. And thanks for the appreciation.

      All the best for the launch.

      Aditya

  34. aman September 22, 2010 at 2:21 pm #

    hi aditya,

    do you have aim or msn or gchat?

    please email me.

  35. salees September 23, 2010 at 11:35 am #

    Hey, amazing plugin. Howeve, I am using playmaker 3 theme.
    It requires that I set a custom field “thumbnail” and i set the path for it. How can i make the thumbnail value automatically the thumbnail that the plugin creates.

    • Aditya Mooley September 23, 2010 at 2:06 pm #

      @salees
      You will have to make the following changes to the plugin code to make this work. But remember, these changes will be lost if you update your plugin. Here’s the code that you should add/replace –

      Find:
      $thumb_id = apt_generate_post_thumb($matches, $key);
      and replace with
      $thumb_id = apt_generate_post_thumb($matches, $key, $post_id);

      Find:
      function apt_generate_post_thumb($matches, $key)
      and replace with
      function apt_generate_post_thumb($matches, $key, $post_id)

      Find:
      require_once(ABSPATH . '/wp-admin/includes/image.php');
      and add the following just above it
      add_post_meta( $post_id, 'thumbnail', $url );

      The above changes will add a new custom field “thumbnail” to the post with the URL of the thumbnail generated by plugin.

      HTH

      • salees September 24, 2010 at 1:46 pm #

        Thanks but i just did some new posts .. it is still showing the categories id image. And there’s no custom field in the post with the name “thumbnail”. Appreciate your help.

  36. Kadu September 23, 2010 at 10:35 pm #

    Hello Mooley,

    I`m trying to use your plugin but when I try in my oficial page, this send a log message (apache log) that the plugin “premature end”, can I enable a “debug” mode, to try discover whats happening ?

    I`m test too in a small blog, and work fine, the oficial have +- 5k image files

    Tks

    • Aditya Mooley September 24, 2010 at 2:03 pm #

      @Kadu – Is the plugin generating thumbnails for some posts before failing? If yes, then this is an expected behavior. Just reload the page generating the thumbnails and it will start from the post where it failed previously.

      • Kadu September 24, 2010 at 4:15 pm #

        Yes, 16% of images, I will try now to reload a page.

        Tks

      • Kadu September 24, 2010 at 9:18 pm #

        I’m trying to reload a page, but still stop in 16%,

  37. Kadu September 25, 2010 at 4:11 pm #

    I’m looking in my database, after pass auto thumbnail, the number of posts without “_thumbnail_id” still the same.

  38. Paul October 1, 2010 at 12:20 pm #

    I am not sure why this isn’t working for me, but a friend suggested that it may be the theme. I’m using BuddyPress Daily Theme by Tammie Lister at Logical Binary (Incsub) on WordPress 3.0.1. I also am running the latest version of Buddypress. It seems that the functions.php and home.php have the necessary calls in PHP. Any thougths what might be the problem?

    • Aditya Mooley October 1, 2010 at 12:25 pm #

      If the plugin is doing its job, then you should see the generated thumbnail on the post edit page. Just open any post which you know has a image in post and this plugin has ran through it and check whether the thumbnail is generated.

      Also, make sure that you have followed Mark’s instructions for adding support for this feature in admin. Link to his blog can be found on the top of this post.

  39. Lars October 1, 2010 at 1:09 pm #

    Think buddypress ist not the not the cause of the problem. Works fine for me with BP 1.2.5 (Theme Incsub Scholar) and WP 3.0.1!

  40. Dan October 1, 2010 at 8:41 pm #

    Hey Aditya,

    I really love your “Auto Post Thumbnail” plugin on WordPress, it works great!

    But is their anyway that I can insert a default image if the post has no image?

    Some of my posts have no image and it just shows up blank and it does not look good on my blog, if you could insert a little code to include a
    default image if there is no thumbnail that would be great.

    I already have a default image ready I just need the code!

    Thanks so much and keep up the great work!

    -Dan

  41. logan October 2, 2010 at 4:49 am #

    Is there a way to setup a cron job that will check posts automatically for me? without me having to login to wordpress

    • Aditya Mooley October 4, 2010 at 11:04 am #

      @logan – what do you want the cron job to check for? The plugin is already capable of generating a thumbnail for future posts when they go live. Is there anything else that you want the cron job to look for?

  42. Fikri Rasyid October 14, 2010 at 8:54 am #

    Hello Aditya, i have to say this: thanks! your plugin rocks. I tested it on live site with more than 200 posts and it went well. However, there’s a time where the theme is already use thumbnail stored in custom field so what we have to do is moving the path from meta_key for example post_plugin into _thumbnail_id. I tried to modify your plugin but it didn’t work well. Do you have any idea to do so? :)

    • Aditya Mooley October 14, 2010 at 9:05 am #

      Remember that _thumbnail_id doesn’t store the path of the thumbnail. It just stores the id of the image. The image in question has to be added to wordpress media collection so that it can get the unique id in order for it to be used as post thumbnail.

      • Fikri Rasyid October 14, 2010 at 6:59 pm #

        Ah, so the _thumbnail_id keep an ID not the image path? Sounds enlightening. I’ll tweak it again :D

  43. J L Gatewood November 1, 2010 at 5:33 am #

    I had been looking all over for something like this!! I switched to a theme that uses featured thumbs for the front page… I didn’t feel like going back to all 300+ posts to do this… Thank you!

  44. Sharon November 4, 2010 at 2:30 am #

    Hi there, OMG, I wish i knew about this a month ago, spent last month trying to get “get the image” plugin to work with scheduled posts but can’t/

    So I’ve installed yours but still now working so assuming I need adjustments to the code. Problem is, done so much fiddling, not sure where to find right place.

    Site is http://www.trafficinternet.org. See Home pageleft? No images. the others still have the “get the image” code.

    Any ideas. Theme is lifestyle 4.0 studiopress

    Thanks

    Sharon

  45. Sharon November 4, 2010 at 2:46 am #

    just to add sorry, I changed the code to reflect a response above where the person was using theme using custom field. I changed my code and it still didnt work.

    Sharon

  46. Sharon November 5, 2010 at 1:26 am #

    no ideas how to get this to work with studiopress lifestyle 4.0 anybody? Using scheduled posts?

    Sharon

  47. Jos Velasco November 6, 2010 at 11:56 am #

    Hello Aditya:

    Is there a way your plugin sets the attribute “title” to the images?

    I think it is not doing it.

    Visit my site, some movies of the home page do not show the title if I hover them. If I enter the gallery and manually set the image as featured it works.

    http://frasesdelapelicula.com/

  48. Denise November 7, 2010 at 10:51 pm #

    Hello, it looks like the 3.2 upgrade has caused a bug in the auto post thumbnail. The thumbnail are no longer posting automatically unless you go to setting and manually run to generate the thumbnails. Will you look into fixing this soon?

    Thanks for your time

    Denise

  49. Sharon November 8, 2010 at 3:05 am #

    so i got the images working by using this code in my home page:

    ‘alignleft’ )); ?>

    BUT: the scheduled posts are still not showing images automatically. I have to go into the admin panel and press “generate thumbnails”

    Can anybody help please?
    SHaron

    see this site for an example: http://www.newchristmas.info

  50. Sharon November 8, 2010 at 3:06 am #

    sorry, half the php code is missing from my comment above.

  51. Lukas November 13, 2010 at 7:14 am #

    Hello, I’ve a little problem with getting your plugin to work. After turning it on and manually used option generate thumbnails it generate empty thumbs for every of my 300 posts ( all of them have images in content).

    So I’ve deleted thumbs from posts manually and run again ‘generate thumbnails’ option, but it ends the same. Now I have thumbinals thats leads nowhere and because of that not showing.

    Plugin creates thumbinal ‘/wp-content/uploads/2010/11/krety8.png’ but I dont even have this catalog ‘/2010/11/’ on my server.

    Can you please show me what I’m doing wrong?

    • Aditya Mooley November 15, 2010 at 9:19 am #

      @Lukas – Make sure that the uploads directory is writable by web server. The plugin creates the folders and files inside uploads directory when generating the thumbnails.

  52. Lukas November 16, 2010 at 10:41 am #

    Hello Aditya, thanx for your quick answer. I’ve figured out that empty thumbs wasn’t fault of your plugin.

    Plugin was generating empty thumbs because of wrong setting in wordpress default upload folder. I’ve changed it to wp-content/uploads and it worked! Thank you again for amazing plugin.

  53. KIt November 16, 2010 at 11:19 pm #

    Hi Aditya …

    I’m having the same problem as Denise… I’ve tried your suggestion to downgrade but it seems like the plugin is no longer automatically generating thumbnails… I to manually generate them now… I’m wondering if there was a bug or may be a plugin that might be causing this problem?

    • Aditya Mooley November 17, 2010 at 9:00 am #

      @KIt – I tried once again with my test setup of wordpress 3.0.1 and its working perfectly for me.

      Can you setup another wordpress on the same server where you are hosting your site and test whether the plugin is working?

  54. Zhono November 28, 2010 at 5:54 pm #

    Same question as someone already asked before: can I setup a cron in cpanel to run it. Basically, I’m using wp-robot to automatically create posts with Amazon products, and it runs every few hours with a cron job. Since those posts aren’t created in the editor, I have to run the tool to create thumbnails for existing posts. I want to automate that process, so I don’t have to go back 6 times a day, just to make thumbnails. And if I don’t do it at all, my site looks like crap.

    So. Any way to run it with a cron?

    Great plugin, by the way. Most useful one so far.

    • Aditya Mooley November 29, 2010 at 9:01 am #

      No, currently its not possible to setup a cron job to generate the thumbnails. But I will look into the possibility of doing this. Cannot commit on the timeframe though. I will update you if I add this feature.

      Thanks for using this plugin and appreciating my work.

      Aditya

  55. SK November 30, 2010 at 6:44 am #

    Aditya,
    I noticed a huge change in functionality in your plugin after a recent update.

    Previously it would automatically set the first image of a post as the “featured image.” And that was it. Perfect! :)

    With the recent update, it is also selecting the first image from the body of a post even if it is “legacy media”. In my situation, these old-format files aren’t given an entry in the Media Library because they were uploaded before that feature existed. Your plugin is automatically creating entries in the Media Library for each of these files. Unfortunately, the process is messy. The addition of legacy-files results in tons of entries into the Media Library without titles. These files also haven’t been “attached” to a particular post either.

    Do you have a suggestion on how I can tweak the plugin to ignore legacy files? Maybe even offering an option would be helpful.

    • Aditya Mooley November 30, 2010 at 9:03 am #

      @SK – This feature of adding an entry to Media Library is there from the first release itself.

      If the image is not the part of Media Library, then the plugin fetches that image (considering that it is remote), adds it to media library and makes it a post/featured thumbnail. This is so because wordpress requires the post thumbnail to be a part of Media Library.

      I do noticed that these images are not getting *attached* to any post. I am looking at this issue right now and will come up with a fix as soon as possible.

      Finally, to have the plugin to ignore the legacy files (and the remote files as well), search for the following code in the plugin file and comment it out.
      $thumb_id = apt_generate_post_thumb($matches, $key);
      On commenting the above code, the plugin will generate post thumbnails only if it finds the file from Media Library.

      Thanks for reporting this issue.

      Aditya

      P.S. I think the plugin should now have a setting page where user will be able to manage various options. :)

      • Sahas Katta November 30, 2010 at 11:47 am #

        Aditya,
        Thanks so much for clarifying those details!

        I’ve been using your plugin quite often on my beta test environment before I launch my new WP site. I’ve commented out the code and I just ran it. Works like a charm. I’m using it along with Alex’s Regenerate Thumbnails plugin. Saved me having to go through nearly 1000 articles, some of which have 10 images in them.

        Anyways, I have another slight challenge for you. ;) In March 2008, WP switched from the old-school myimage.thumbnail.jpg to the new post-thumbnail technology. As a result, none of my old posts can be assigned a featured thumbnail. Even the Regenerate Thumbnails plugin won’t solve that issue, because it’s legacy media.

        I could use your import feature, however, that will create new entires in the Media Library, when an “old fashion” entry already exists. Is there any way to upgrade those with a query?

        File names for thumbs looked like this in the past: myimage.jpg and myimage.thumbnail.jpg

        I went through my DB to dig into this a bit, here’s what I found: http://pastebin.com/TmLpzLUb

        But seriously great work! Long-time WP users will definitely appreciate this!

        • Aditya Mooley November 30, 2010 at 1:25 pm #

          @Saha – Thanks for the update. Nice to know that it worked for you after modifications.

          Regarding upgrading from legacy media, I don’t think any upgrade path is possible as it includes change in every img tag in each post.

          But one thing that I haven’t done in my plugin is, checking the image URL to find whether its local or remote. Right now, I am checking for a CSS class that wordpress adds for local images ;) . This might have to be changed (or added) to the code in order to support the legacy media.

          I was about to release a new bug fix kind of version today but now will hold on and check what can be done for this issue.

          You may want to follow me Twitter (@adityamooley) to know about the new release.

          Aditya

        • Aditya Mooley December 2, 2010 at 9:31 am #

          @Saha – Update to plugin is now available but the better support for legacy media is still not there. Can you tell me the wordpress version which used to create such URLs? I will have to actually install it and try there.

          Aditya

        • Sahas Katta December 2, 2010 at 9:58 am #

          Thanks for the update! (Hopefully the comment out tweak still works.)

          The change to the modern configuration changed when WP 2.5 was released on March 29th, 2008. You can see how upload styles changed by comparing the posts on my site before and after that day: http://skattertech.com/2008/03/

          I also noticed another minor bug. All my pre-”March 2008″ have an in the Media Library for the image file I uploaded. So if I uploaded “myphoto.jpg”, it’s in the dashboard. However, the “myphoto.thumbnail.jpg” files, which were automatically created in the past, aren’t accessible anymore through the dashboard interface anymore. As I had shown you in pastebin example, notation of those files are still present in my database. (As I assume they would be with other people’s installations.)

          Anyways, your “import feature” is causing those “*.thumbnail.jpg” files to be imported as a new entry into the Media Library. It’s not your fault, but it’s a bit annoying.

          Here are somethings I noticed:
          1) Regenerate Thumbnails plugin properly generates all the new file custom image sizes for all the old-format images in addition to the new ones. The “.thumbnail.jpg” file isn’t removed.
          2) The post content of old article still has “.thumbnail.jpg” files in it. As a result, your plugin is targeting the first file in there.

          My dream tool would need to do the following to fix all my hundreds of posts pre-2008. 1) upgrade the database post_meta entry 2) so a (possibly very dangerous) search and replace regex to fix the urls in the old posts from using “.thumbnail.jpg” to the new thumbnail files.

          P.S. One possible solution would be for your plugin to do this when searching for the first file in a post. If it sees the img src value ending in .thumbnail.jpg, it would drop the ‘.thumbnail’ portion and set featured image for the original image.

  56. Blair Damson November 30, 2010 at 10:00 am #

    Aditya,

    What size image works best in posts for converting into a thumbnail? Most of my image thumbnails got chopped in half on my homepage when I ran your plug in. http://www.WriteToSell.com

    Blair

    • Aditya Mooley November 30, 2010 at 1:12 pm #

      @Blair – There’s nothing like *best image size*. Infact, my plugin doesn’t do the cropping job. I have left it to WordPress to handle it. You may want to take a look at Mark Jaquith’s blog post (link on top of this page) to understand how cropping of post/featured thumbnails work.

      All the best.

  57. BigSean December 2, 2010 at 11:44 pm #

    The download link is broken and can’t update from inside of WordPress

    • Aditya Mooley December 3, 2010 at 10:01 am #

      Strange! Both the things are working for me. Can you please try again?

      Aditya

  58. Keith December 7, 2010 at 3:16 am #

    Would it be possible to look for an image in the gallery of the post and to use it for the featured image instead of looking in the post content for the image?

    The way my templates are setup it uses the featured image to display the image as a thumbnail on a page and as a picture within the post.

    Thanks!

  59. Annet de Graaf December 9, 2010 at 10:45 pm #

    Fantastic!!! You made my day guys.

  60. Jean-Paul Horn December 10, 2010 at 12:06 am #

    Hi Aditya,

    I think the auto post thumbnail functionality for scheduled posts is broken (at least on our end). Any scheduled post doesn’t get the featured image (post thumbnail). If we publish directly it’s fine, but just not for scheduled posts. Is this something specific to us or did it break with the recent WordPress updates? (we’re on WP 3.0.3).

    Thanks,
    Jean-Paul

  61. Ben December 10, 2010 at 4:36 pm #

    I dont know why your plugin doesnt work with my theme. I try regenerate thumbnail, no result. Publish a post, no result.

    Can you check on my problem? If yes, i send you my wp login to see what the problem.

  62. jason December 10, 2010 at 10:34 pm #

    HI

    got to say love your plug – in – it is so much easier than get the image for me as I can’t follow code much

    however I’m the same as others here —

    It only works if I go into it and push the button to update the images – it will not do it automatically.

    not sure why this is – but open to suggestions to resolve.

  63. Rany December 21, 2010 at 6:22 pm #

    Hi,
    Is there a way for the plugin to generate thumnail every 5 hours automaticly without me pushing the button?

  64. Jefferson Pals January 12, 2011 at 9:47 pm #

    For some reason the plugin does not seem to work if the posts are coming from WordPress for iPhone. I have to go back to the web version and press the Update button for the post and then the Featured Image is created.

    I’d love to see this fixed if at all possible.

    • Aditya Mooley January 13, 2011 at 11:07 am #

      Thanks for reporting this. Frankly, I never tested this stuff. Will try to get this fixed in the next release.

      Aditya

    • Erwin Vrolijk January 18, 2011 at 7:13 pm #

      We also saw this problem. We managed to fix this by adding the following line to the top of the plugin:

      add_action('publish_post', 'apt_publish_post');

      The plugin still seems to work as described + iphone posting.

  65. Douglas Karr January 15, 2011 at 9:27 pm #

    Great plugin, Aditya! I’m updating my theme right now at the Marketing Technology blog and this is just what I needed!

  66. Erwin Vrolijk January 18, 2011 at 8:23 pm #

    This plugin duplicaties the image if it can’t find the thumb-id in a css class. As a result the imagelibrary can get full of duplicates.
    We’ve added the following code, which looks for the url in the local database and get’s the id from there. This code is added on line 255 in auto-post-thumbnail.php:


    if (!$thumb_id) {
    $image = substr($image, strpos($image, '"')+1);
    $result = $wpdb->get_results("SELECT ID FROM wp_posts WHERE guid = '".$image."'");
    $thumb_id = $result[0]->ID;
    }

  67. TraXim January 19, 2011 at 1:18 am #

    The plugin does not work. It adds no pictures to automatically. I use the Windows Live Writer. Please update. Thank you for your efforts.

  68. Tim January 19, 2011 at 3:59 am #

    Just updated to the latest version of this plugin and now my post images don’t show up. Tried uninstalling and reinstalling, no dice. Only way I get images is to regenerate button, seems like a few people are having this issue too. Really great plugin though anyway to go back to the older version?

  69. Aditya Mooley January 19, 2011 at 10:21 am #

    @Erwin – I was using publish_post action in previous versions of the plugin. Recently I changed it to use transition_post_status as it is supposed to work for any type of content, even for the custom post types. For me, everything is still working fine but looks like I will have to add publish_post action back in plugin since lot of users are complaining after the recent release.

    @TraXim, @Tim – What is the version of WordPress you are using? I can try to install that version and check the plugin with it.

    • Erwin Vrolijk January 19, 2011 at 1:55 pm #

      What do you think of our solution to prevent duplicates?

      • Aditya Mooley January 19, 2011 at 2:12 pm #

        Even that looks fine. But instead of replacing line 255 with that code, I would put it above the current condition on line 254. This is because, if a user adds an image by URL, wordpress won’t get it locally first. But for featured thumbnail, we need the image locally and that is what the code on line 255 does.

        • Erwin Vrolijk January 21, 2011 at 8:00 pm #

          This was exactly what I meant. I saw your update to the pluging today and it’s identical to our code!

          Regards,
          Erwin Vrolijk
          Snow

    • TraXim January 19, 2011 at 2:56 pm #

      Its the newer Version, i think 3.0.1 or?

    • Tim January 20, 2011 at 4:49 am #

      I am using the latest wordpress 3.0.4.

  70. TraXim January 19, 2011 at 3:01 pm #

    not 3.0.1
    i have 3.1 xD

    • Aditya Mooley January 19, 2011 at 3:25 pm #

      Well, your blog says its 3.0.4 :) . I am going to release a new version soon. Let’s hope it will work for you.

  71. olmar January 19, 2011 at 7:16 pm #

    Thanks for great plugin.

    One question. When the post is published via “Publish” button everything is ok and the plugin generates thumbnail. But when we have delayed posts(post is published without “Publish” button) the plugin generate no thumbnail.
    Any help?
    Thanks.

  72. Aditya Mooley January 20, 2011 at 8:27 am #

    @TraXim, @Tim, @olmar – A new bug fix version of the plugin has been released. Please update and see if everything is working now.

    • Tim January 20, 2011 at 10:23 pm #

      Seems to be working for me now. Thank you for the quick update.

  73. TraXim January 21, 2011 at 3:09 am #

    Its works thans the Plugin :D

  74. olmar January 21, 2011 at 4:04 pm #

    It works! Thank you for the quick response.

  75. lisa January 26, 2011 at 5:48 pm #

    This is a great plugin. One minor improvement would be to take the first thumb image. Instead of the first image. This can help speedup the website and save traffic. For example:

    This plugin takes the first image, so 10 images = 700kb data
    if it would take the first thumb it would be 150k for 10 images.

    No point in resizing a 600×400 pixel image and showing it as 120×80 if there is already a small image that is 120×80.

    • Jeffeson Pals January 27, 2011 at 9:01 am #

      Lisa,
      I can say from my experience that the size you need is dependent upon the blog design. I need large featured images for my blog compared to yours which must only need small images so that wouldn’t work for everybody.

  76. Jeffeson Pals January 27, 2011 at 9:01 am #

    Great Job On The Updates!!!
    Posts from my iPhone now automatically work with the plugin.
    Thanks!

  77. Haseeb January 27, 2011 at 11:10 pm #

    Thanks for such a great plugin!

    How can i change the size of the image produced by the plugin. By default it gives me rectangular image and i want square.Please solve this problem!

    Regards,

  78. Mike January 31, 2011 at 10:48 am #

    Hi.. firstly Im new to wordpress.. I have activated the plugin and generated thumbnails ( so you app siad) But where are they and how can I access them.. Where do they appear?
    Sorry but Im a little confused..
    Thanks for listening

    • Aditya Mooley January 31, 2011 at 11:01 am #

      @Mike – Read a post by Mark Jaquith about using featured thumbnails. The link to his post is in the beginning of my post.

      Cheers.

  79. Siren17 February 9, 2011 at 10:26 am #

    Ok, can someone please help me? I just installed this and ran it and now my site doesn’t work at all. Take a look at the main page, it’s a bunch of errors. How do I fix this? Thank you.

  80. Siren17 February 9, 2011 at 11:22 am #

    Ok, it’s only a problem with the Bueno theme – just so you know. I’ve switched themes and everything seems alright so far.

  81. Siren17 February 9, 2011 at 12:21 pm #

    Ok, after trying like 6 new themes I’ve decided I NEED Bueno. Please advise on how to fix. This is what shows up when I try using the Bueno theme.

    Warning: getimagesize(D:\Hosting\6109288\html/wp-content/uploads/) [function.getimagesize]: failed to open stream: No such file or directory in D:\Hosting\6109288\html\wp-content\themes\bueno\functions\admin-functions.php on line 575

    Warning: file_get_contents(D:\Hosting\6109288\html/wp-content/uploads/) [function.file-get-contents]: failed to open stream: No such file or directory in D:\Hosting\6109288\html\wp-includes\media.php on line 253

    Warning: imagecreatefromstring() [function.imagecreatefromstring]: Empty string or invalid image in D:\Hosting\6109288\html\wp-includes\media.php on line 253

    Catchable fatal error: Object of class WP_Error could not be converted to string in D:\Hosting\6109288\html\wp-content\themes\bueno\functions\admin-functions.php on line 580

  82. Jason Haloossim February 12, 2011 at 9:22 am #

    Hi there Aditya…

    So I love this plugin!! One problem I am having is that it is not saving a new image thumbnail with the dimensions it needs to be….it is simply resizing (scaling) the larger images, and this is creating blurry and pixelated thumbnails. The thumbnails are being scaled.

    Any solution for this?

    You can see what I am referring to by right-clicking on the thumbnails in my blog here:

    http://www.interiordesignpro.org/blog/

    I have in functions:

    add_theme_support( ‘post-thumbnails’ );
    set_post_thumbnail_size( 180, 180, true );

    Also, when I click on the “Generate Thumbnails” button from your control panel, it does not do anything for older posts. I am having to go into each post and re-saving a new version for it to define a featured image.

    Thank you for any help on this!!

    - Jason

  83. Paolo February 14, 2011 at 4:40 am #

    I use a theme that shows images simply attached to posts and I need to create thumbs for those…

    Any way to set featured image from 1st post attachment even if the image has not been inserted into the post?

    Thanks

    • Mirko February 24, 2011 at 9:06 am #

      I installed your plugin, so I can use it with Swift theme.
      But I’m having error when I open plugin page, Firebug displays:

      a.widget is not a function
      wp-content/plugins/auto-post-thumbnail/jquery-ui/ui.progressbar.js?ver=1.7.2
      Line 13

      When I click Generate Thumbnails I get following error:

      $(“#genpostthumbsbar”).progressbar is not a function
      http://www.kgsport.info/wp-admin/options-general.php?page=generate-post-thumbnails
      Line 150

      I tried disabling all other plugins, but that didn’t help.

      Do you have any idea what can be causing this? :(

      • kenarneson February 27, 2011 at 8:45 am #

        I am having the same problem. Seems like jQuery is not being loaded properly or something. Maybe there’s a version mismatch?

        • kenarneson February 27, 2011 at 10:45 am #

          I tried another plugin that also uses the jQuery-ui and it also breaks in the same way. Probably something about that in the newest version of WordPress (3.1) which breaks it.

        • gnoboy March 1, 2011 at 12:56 am #

          yes ,I have the same problems.

  84. Shivam February 22, 2011 at 11:50 pm #

    Your plugin is magical, I swear.

    Thanks :)

  85. gnoboy February 26, 2011 at 4:10 pm #

    hi
    this plugin don’t work for me , i think it is not compatible with wordpress 3.1. i hope new version comming soon.

  86. Aditya Mooley March 1, 2011 at 11:10 pm #

    Hi all,

    Released a new version of plugin which fixes the Javascript error. The regular thumbnail generation of post add is working fine with WordPress 3.1

    Let me know if the release solves the problem.

    Aditya

    • gnoboy March 2, 2011 at 2:32 am #

      thanks
      now the plugin load but after the work done for the 2500 post nothing change , all my post still don’t have thumbnail. any solutions please ?

Trackbacks/Pingbacks

  1. [Wordpress Plugin] Automatic Post Thumbnail at SANIsoft – PHP for … | WordPressPlanet.com - April 19, 2010

    [...] The rest is here: [Wordpress Plugin] Automatic Post Thumbnail at SANIsoft – PHP for … [...]

  2. Wordpress Plugins »  Wordpress Plugin Automatic Post Thumbnail at SANIsoft – PHP for … - April 19, 2010

    [...] the rest here: WordPress Plugin Automatic Post Thumbnail at SANIsoft – PHP for … hopfeed_affiliate='fwsjay'; hopfeed_affiliate_tid=''; hopfeed_cellpadding=5; [...]

  3. 12 Wordpress Plugins I Can’t Live Without | Daily Window - July 30, 2010

    [...] these lines, Auto Post Thumbnail doesn’t deserve its own line item, but it will automatically set your featured image from any [...]

  4. ArcIris · WordPress Random Posts With Thumbnails - September 21, 2010

    [...] also made use of the excellent Auto Post Thumbnails plugin to create thumbnails for all the old posts which had images in the [...]

  5. Small bugfix of wordpress plugin « Technimad's Blog - March 23, 2011

    [...] created a small bugfix patch, which is part of this plugin since version [...]

  6. How To: Featured Image Thumbnails on your BlogPress WordPress Blog | Pange's iPad Blog - April 19, 2011

    [...] solution? Auto Post Thumbnail by Aditya Mooley! This plugin automatically generates a post thumbnail (featured image) purely from the first image [...]

  7. Les extensions Wordpress du Katorz | Katorz' - June 22, 2011

    [...] Auto Post Thumb­nail : Génère auto­ma­ti­que­ment la vignette d’un article à par­tir de la pre­mière image de l’article. Aller sur le site de l’extension [...]

  8. A Test From My iPhone | Matthew Smith - July 27, 2011

    [...] Seems to have worked great! I’m using the Auto Post Plugin by Aditya Mooley. The only problem i found was that to avoid duplicate images, i have to go in [...]

  9. Design Increases Traffic 25% - September 16, 2011

    [...] also incorporated WordPress’s Post Thumbnail into our blogging template and added a plugin to automatically generate the post thumbnail from the first image in the blog post. This way I didn’t have to train all the bloggers on [...]

  10. 使っているプラグイン一覧 | Wordpress-demo - March 4, 2012

    [...] http://www.sanisoft.com/blog/2010/04/19/wordpress-plugin-automatic-post-thumbnail/ Breadcrumb NavXT:パンくずリスト http://mtekk.us/code/breadcrumb-navxt/ No Self [...]

  11. 立ち上げたばかりのワードプレスに入れたい10個のプラグイン。[WPログ] | kitLog - May 21, 2012

    [...] Auto Post Thumbnail 大好きなプラグイン。編集中の記事に貼った、一番最初の画像をアイキャッチにしてくれるプラグイン。 いちいち手動で登録する必要がありません。自分でアイキャッチを登録するとそれが反映されます。 ⇒Auto Post Thumbnail [...]

  12. WordPressのテーマ作成時に、プラグインを盛り込みながら仕上げていくあなたへ | Dabide& - May 24, 2012

    [...] [WordPress Plugin] Automatic Post Thumbnail at SANIsoft [...]

  13. Automatically Generate Thumbnails For Your wordpress Posts : Plugin - HexCoders - June 3, 2012

    [...] Automatic Post Thumbnail : WordPress Plugin[...]

  14. How WordPress gets me out of self-inflicted pain | NJN Network - June 13, 2012

    [...] me – there is a WordPress plugin for everything.  Sure enough there is a  WordPress Plugin – Automatic Post Thumbnail. Lunch with sardines and wine while Automatic Post Thumbnail chugged [...]

  15. Wordpress 3.4 – alte Artikelbilder werden nicht mehr angezeigt - ITler.NET - Der Blog für ITler und Sysadmins - June 21, 2012

    [...] Hersteller: Automatic Post Thumbnails [...]

  16. [wordpress:] kleine vorschaubildchen einbauen | neues aus der roiberhöhle - July 9, 2012

    [...] wird das Bild nicht automatisch gesetzt, dafür gibt es auch ein Plugin namens Auto Post Thumbnail (Plugin-Seite, [...]

  17. Auto Post Thumbnail | Best Plugins - wordpress – widgets – plugin 2012 - October 2, 2012

    [...] For more details, see http://www.sanisoft.com/blog/2010/04/19/wordpress-plugin-automatic-post-thumbnail/ [...]

  18. How to Generate Post Thumbnails/Featured Image Automatically in Wordpress | Durofy - November 13, 2012

    [...] Page on Developer’s Site: sanisoft.com/blog/2010/04/19/wordpress-plugin-automatic-post-thumbnail Also Check OutHow to Add Google Analytics on WordPress Without Using PluginsRelated [...]

  19. 2012年版!ブログで絶賛稼働中のWordPressプラグイン28選 | Mori2nd Lab - December 31, 2012

    [...] [WordPress Plugin] Automatic Post Thumbnail at SANIsoft [...]