Take the 2-minute tour ×
WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. It's 100% free, no registration required.

When it comes to excerpts, do you believe TimThumb or WordPress thumbnails is the way to go? And why? Answers will not be graded (but may be criticized).

share|improve this question

closed as not constructive by Brian Fegter, Wyck, toscho Sep 28 '12 at 21:58

As it currently stands, this question is not a good fit for our Q&A format. We expect answers to be supported by facts, references, or expertise, but this question will likely solicit debate, arguments, polling, or extended discussion. If you feel that this question can be improved and possibly reopened, visit the help center for guidance.If this question can be reworded to fit the rules in the help center, please edit the question.

    
Way to go for what? This question makes no sense to me without specific scope to measure against. I am considering closing it as "not constructive" or turning into community wiki. –  Rarst Jun 30 '11 at 16:29
    
I'd go with the WP way. I don't see any advantages in using TimThumb –  onetrickpony Jun 30 '11 at 16:30
1  
@One Trick Pony - IMO the only thing TimThumb has that WP thumbs need is on-the-fly generation. I've had many situations where a new layout required new thumbnail sizes, having to re-generate WP thumbs is no fun. TimThumb doesn't play well with cache plugins though without significant hackery, so no go for me. –  Milo Jun 30 '11 at 16:39
    
I'm all about the WP way. Anything WP can do, I stick with. I don't like bringing in external dependencies. The WP thumbnail feature may be a little weak right now.... but IMO it's not hard to add image sizes, and regenerate thumbnails if needed. –  Rev. Voodoo Jun 30 '11 at 16:53
1  
@Milo: that's not a feature, that's a bug :) If a thumbnail size is missing in WP you can regenerate it before it gets displayed on the screen –  onetrickpony Jun 30 '11 at 17:42

4 Answers 4

up vote 4 down vote accepted

In my opinion the built in <?php add_image_size( $name, $width, $height, $crop ); ?> function is much more flexible, easy and with less overhead. It does resize-crop, so I don't see a reason to go back to TimThumb (which I used extensively in the past).

share|improve this answer
    
I didn't even realize that function existed! –  Lucas Jun 30 '11 at 21:55
1  
yes it's very nice I use it all the time. For instance: if you have a frontpage slider with some weird image dimensions jut add <?php add_image_size( 'weird-slider-main-image', 634, 74, true ); ?> and then all you need is to call it <?php if ( has_post_thumbnail() ) { the_post_thumbnail( 'weird-slider-main-image' ); } ?> –  Daniel Sachs Jun 30 '11 at 22:00
1  
Oh and one last note. If you add this function to an existing site your thumbnails will not be regenerated for past images, but you can use Ajax Thumbnail Rebuild plugin to rebuild the thumbnails for all the uploaded images –  Daniel Sachs Jun 30 '11 at 22:07
1  
@DanielSachs dynamic regeneration is one of the primary reasons I prefer timthumb. Also, I don't necessarily want to use the wordpress media uploader, and rather use FTP/SCP/Git. Timthumb also supports zc=2 option which I find very useful, and different level of compression. I find the way wordpress statically stores all thumbnail sizes inefficient, whereas timthumb just caches what's actually accessed with only one source version. –  Yoav Aner Feb 7 '12 at 13:21
1  
@Daniel there is one limitation on this function ... which is the crops are all from the centre. This is really bad if you have a headshot (like in Lucas's picture). However i agree this should be the best approach –  Damien Aug 29 '12 at 19:47

WordPress image handling, without question.

The only thing that TimThumb has that is currently not possible with core image handling is zoom crop. Everything else can be accomplished using core image handling, including on-the-fly resizing.

I see absolutely no advantage to using TimThumb, and only disadvantages. It was a great tool prior to WordPress 2.9, but has been essentially unnecessary since then.

EDIT

Advantages to using core system:

  1. Familiar UI (Media Manager, "Featured Image" metabox), rather than custom fields
  2. Implement in template using core WordPress functions
  3. Less overhead
  4. Cross-Theme support
  5. Thumbnail image handling remains extensible via Plugin
  6. Thumbnail image handling maintains forward-compatibility with WordPress core
share|improve this answer
3  
Actually you can hook custom crop on top of core functionality, it's just more messy than usual. I have answered question about such recently. –  Rarst Jun 30 '11 at 21:21
    
@Rarst can that do zoom-crop? If so: checkmate. –  Chip Bennett Jun 30 '11 at 21:28
    
yep, dimensions for source and target areas do not need to match. –  Rarst Jun 30 '11 at 21:34
    
I know all WooThemes still use timthumb for dynamic image requests. But one downside is that some CDN's don't support origin-pull so timthumb never sends the image :( –  Damien Aug 29 '12 at 19:48

Timthumb's ONLY advantage is in reducing the quantity of files stored on the server. By default Wordpress creates 3 images from each upload. If you add additional sizes it will create a new image file for each of those as well.

Basic Usage: 1000 Posts with an average of 5 images per post will produce a minimum of 15,000 images.

Using 5 custom sizes for the crop value used in post listings, etc... 1000 Posts with an average of 5 images per post will produce a minimum of 40,000 images.

Shared hosting environments can limit the number of files on a server to 50,000 or less... thus the helpful use of timthumb which would keep the files stored lower.

That's my 2 cents....

share|improve this answer

I choose the third option:

http://wordpress.org/extend/plugins/custom-image-sizes/

It generates custom thumbnail sizes on the fly, while still being integrated into WordPress.

Really, with that plugin around, you should never need to use TimThumb again.

share|improve this answer
    
The thing I like about this: ease of use. The thing I hate: it's not hard-coded into the theme. –  Lucas Jul 1 '11 at 15:18
    
I'm sure you could safely bundle it in a theme, with a little thought. –  scribu Jul 1 '11 at 16:36

Not the answer you're looking for? Browse other questions tagged or ask your own question.