> ## Content Index
> Fetch the complete content index at: https://www.chrismessina.me/llms.txt
> Use this file to discover other available public pages before exploring further.

# WP-Imagefit proportionally resizes images to fit your blog template
- URL: https://www.chrismessina.me/blog/wp-imagefit-proportionally-resizes-images-to-fit-your-blog-template/
- Published: 2007-11-17T01:52:56.000Z
- Updated: 2026-03-25T03:40:28.000Z
- Author: Chris Messina
- Tags: design, Open source, plugin, Technology, The Web Arts, Web building, WordPress, wp-imagefit

[](http://factoryjoe.com/projects/wp-imagefit/?ref=chrismessina.me)I'm happy to announce the release of my *second* ever WordPress plugin called [WP-Imagefit](http://wordpress.org/extend/plugins/wp-imagefit/?ref=chrismessina.me). (My first, which I've neglected for sometime, is called [WP-Microformatted-Blogroll](http://factorycity.net/projects/wp-microformatted-blogroll/?ref=chrismessina.me)). WP-Imagefit is extremely simple and serves one purpose: to get images in blog posts to fit inside the columns that contain them. In fact, this plugin is used on this blog, so if you see ever images load wider than the column and then quickly snap to fit the container's width, it's this plugin that's doing that. I originally discovered this trick thanks to [Oliver Boermans](http://www.ollicle.com/?ref=chrismessina.me)' NetNewsWire [Ollicle Reflex](http://www.ollicle.com/2006/nov/28/jquery%5Fnetnewswire%5Fstyle.html?ref=chrismessina.me) style. Working together, he extracted the resizing code into a jQuery plugin called [jquery.imagefit.js](http://www.ollicle.com/eg/jquery/imagefit/?ref=chrismessina.me) and made it available to me for use in my [EasyReader NetNewsWire theme](http://code.google.com/p/nnw-easyreader/?ref=chrismessina.me). I had hacked it to work for my blog theme but decided that I should turn it into a WordPress plugin so I could use it elsewhere (and given that CSS's `max-width` attribute not only wasn't cross-browser, but also shrunk images horizontally, I needed a better solution). So, there you have it. Go ahead and [download it](http://downloads.wordpress.org/plugin/wp-imagefit.zip?ref=chrismessina.me). Installation and setup is standard as long as you have an [hAtom](http://microformats.org/wiki/hatom?ref=chrismessina.me)\-compliant theme like [K2](http://getk2.com/?ref=chrismessina.me) or [Sandbox](http://www.plaintxt.org/themes/sandbox/?ref=chrismessina.me). I have a [WordPress.org](http://wordpress.org/extend/plugins/wp-imagefit/?ref=chrismessina.me) project page setup, the [source is available](http://dev.wp-plugins.org/browser/wp-imagefit/trunk?ref=chrismessina.me) (released under GPL), and if you want something to look at it, here's the [official homepage](http://factoryjoe.com/projects/wp-imagefit/?ref=chrismessina.me). Feedback/feature requests/patches certainly appreciated and encouraged!

---

### 💬 Comments from the original post

**[Matt Herzberger.com &raquo; Blog Archive &raquo; Here is your del.icio.us goodness for 11-18](http://mattherzberger.com/2007/11/18/here-is-your-delicious-goodness-for-11-18/?ref=chrismessina.me)** · 2007-11-18 00:25:49

\[...\] - WP-Imagefit proportionally resizes images to fit your blog template | FactoryCity mely simple and serves one purpose: to get images in blog posts to fit inside the columns that \[...\]

**[Amos Moses Griffin](http://barleyhut.com/?ref=chrismessina.me)** · 2007-11-18 07:27:53

Nice work here Chris. This would solve the problem of post image and theme changes. Seeing that I'm constantly fiddling with my design/theme this plugin would eliminate one headache. I'd hate to say how much time I've spent changing the widths of my photos. Haven't looked at the code yet but it must latch into hentry or entry-content? That's why it'll work on hatom only? In any event, thanks for the hard work and community love. You have my appreciation.

**[Nate Westheimer](http://innonate.com/?ref=chrismessina.me)** · 2007-11-18 12:14:22

Very cool, Chris. Installing it now. I have this problem all the time.

**[Chris Messina](http://factorycity.net/?ref=chrismessina.me)** · 2007-11-18 14:39:44

@Amos: it only support hAtom blogs for two reasons: 1) to selfishly promote hAtom 2) because I don't know how to add multiple search classes to the jQuery code (I simply need to do more research into jQuery!). If you're not using hAtom, just sub out the containers' classes for the hAtom-specific class (.hentry) on line 20 in wp-imagefit.php.

**[Joel](http://euphemize.net/?ref=chrismessina.me)** · 2007-11-20 14:01:05

Any examples available out there in the wild yet Chris?

**[Chris Messina](http://factorycity.net/?ref=chrismessina.me)** · 2007-11-24 23:52:21

Hey Joel, you mean besides my site? ;) Not that I've heard of yet!

**[WP-Imagefit at Camiel Schoonens](http://www.schoonens.nl/camiel/index.php/2007/11/27/wp-imagefit/?ref=chrismessina.me)** · 2007-11-28 00:47:08

\[...\] This plugin is currently only compatible with an hAtom-compliant theme like K2 or Sandbox and can be downloaded here. \[...\]

**[WP-Imagefit, a new plug-in for the masses! at Joshua&#8217;s Blog](http://wolfnix.net/blog/2007/12/wp-imagefit-a-new-plug-in-for-the-masses/?ref=chrismessina.me)** · 2007-12-02 23:37:45

\[...\] is a plug-in that Chris Messina author of FactoryJoe, and Co-Founder of Citizen Space has \[...\]

**[Josh Altemoos](http://www.wolfnix.net/?ref=chrismessina.me)** · 2007-12-02 23:40:16

Hey! I love this plug-in. It is just what I needed to migrate to k2!! Thanks!

**[Jeff](http://journeyguy.com/?ref=chrismessina.me)** · 2008-04-30 08:02:00

I am trying this out on my blog, but it's not working... Either for uploaded images or for linked images.