Post Formats & Misc Coding

After the recent days of cleaning up the link formatting dregs of Movable Type, I got slightly excited about fixing a couple of things that have been on my list, merging a bunch of tags, images in the wrong folder (another shift-from-MT thing), miscellaneous missing formatting … then I discovered the code which wraps an excerpt around a search term – so you can see the term in context – had borked the archive excerpts. So I rewrote a bunch of that. Finally I got to the not-cleaning-up-mess stuff: Post Formats.

I’d written a widget for Lewis Major that shows a list of available post formats, and had been meaning to put it on supernaut for ages. Turned out to be a matter of plonking the code in my already-existing custom widgets file and there it is, in the footer. Then I decided to do something about the Image Post Format, which turned into a coding frenzy. The result is on a single image format post, the inserted image gets yanked, its ID grabbed and used to spit out the full-size image below any content. Rather happy with how that worked out.

Finally, I decided to add a bunch of posts to the Gallery Post Format. Besides being assigned thus, nothing in the template code is different. I haven’t decided if I want to do anything interesting with how the images are displayed, let alone looked around for code that could give me ideas. Mainly it’s so all the posts where I’ve uploaded some kind of collection of images are grouped. Not all though; some posts with a lot of images, like workshop notices, or which induced some vague feeling of “not gallery” are not included.

The others then: Video posts have been around for a while (I need to do something about forcing non-16:9 into pillarbox format); occasionally there are Quotes, usually from books I’m reading; Asides also get some use (this was going to be an Aside before I realised I didn’t know when to stop); and last but used the most, my pseudo-Twitter Status posts, limited to 140 characters by some petty-facist script.