WordPress is great. Jetpack is great.
It is a plugin suite that has many useful little knickknacks. I actually wish there was a plugin where I can create my own suite of plugins so I don’t have to find and download them one by one. Yeah, I have a folder full of them that I manually upload to all new sites (not that I am creating any new sites recently, but I digress). I guess that’s good enough.
Anyway, so Jetpack. At the time of this writing, there are 33 features that you can enable via Jetpack.
This site is pretty much where I come to test things live. I have some local WP installs, but since I’m on shared hosting for most of my sites, it’s easier for me to troubleshoot it here. Besides, it’s kind of fun to see how badly I can royally screw my site and then try to fix it.
Case in point is encountering…
Why did the WordPress Post Thumbnail Hard Crop cease to work?
This was kind of a big deal because I use it as the post excerpt image header. The issues was all of a sudden having the full, un-cropped image as the header and it made things look kind of lame. Comon, I want to sort of look like I know what I’m doing!
Now onward to the troubleshooting… (some are redundant)
- Codex: Function Reference/set post thumbnail size
- WordPress.org: add_new_image Hard Crop Not Working
- StackOverflow: set_post_thumbnail_size() crop not working
- StackExchange: the_post_thumbnail scaling not hard cropping
- StackExchange: set_post_thumbnail_size not cropping featured images
- StackExchange: resize images not crop
Then there was a lot of head banging because nothing seemed to work. So I tried what I should have done to before all of this. I deactivated all the plugins and suddenly, the hard crop worked again with the dynamic image resizing!
It turned out to be a plugin conflict.
But which one? By process of elimination, it turned out to be WP’s Jetpack. And then I remembered that I enabled a bunch of the new features.. one of which was Photon.
When you read the descriptions for Photon, you can see that it is neat. Unfortunately, because it conflicts with the Post Thumb (and TimThumb), it’s kind of a jerk if you rely on controlling your featured images in that manner.
So there you have it. If you’re having issues with the hard cropping with WP Post Thumbnails, try everything! But try deactivating plugins first!
Thank you, this was sending me bonkers! Now fixed in less than ten seconds. 🙂