Resizing and regenerating WordPress upload thumbnails

WordPressFor quite some time, I’ve been wishing the thumbnail images WordPress creates when you upload an image were slightly bigger. The function that generates the thumbnails accepts a maximum dimension as an input parameter, but then the value (a paltry 128 pixels) is hardcoded in the script that calls the function, and there’s no way in the standard WordPress configuration to change the value, other than manually editing the admin script where the call is made.

This is easy enough to do, if you know how to find the block of code in question, but it’s wrong wrong wrong in terms of ongoing WordPress updates: when a new version is released and you update your files, the changes you made will be lost.

So the right way to go about this is with a plug-in, and fortunately there is one. It’s simple and it works. Except for the fact that it doesn’t regenerate any of your existing thumbnails.

Maybe there’s something else out there, but I wasn’t able to find one, so I had to resort to rolling my own.

The script is incredibly rudimentary right now. It’s not a plug-in, it doesn’t interface with WordPress admin at all, setting the file path and dimensions require manually editing variable values in the script, there’s no security, etc. It does seem to work though, which is the most important thing. There were a few bugs earlier on that I believe I’ve squashed, but I can’t guarantee there aren’t others, and given how quickly I put it together this afternoon, with kids screaming and car dealerships calling me every 3 minutes (yeah, that’s another blog post), it’s probably not quite as efficient as it could be. (That’s why I cranked up the max_execution_time and memory_limit values. YMMV depending on how many files you have to process.)

As long as you understand that you’re using it at your own risk, feel free to download the script. In order for it to work it should be placed in your wp-admin directory. And remember, it’s not secured at all, so I recommend uploading it, running it, and then deleting it. (Well, now that I think about it, I’m pretty sure including admin.php does automatically provide standard admin security, but don’t quote me on that.)

If I have the time and if anyone actually cares, I’ll update this and turn it into a proper plug-in with all of the attendant niceties. Otherwise… well… never mind!

Online privacy is an oxymoron

Big Brother is watching youAs I read this summary of complaints about some Google thing, it made me glad once again that I’ve made a reasonable effort to keep my truly private information to myself (as far as I know), and have always tried to keep in mind that anything I put into any Internet-based system, even if it’s supposed to be “private,” is something that could potentially be seen by eyes unknown to me.

Not that I disagree with the people who are pissed about this but… well, if it’s really sensitive information, don’t leave it in someone else’s database.

At this rate, what is the RIAA going to have left to protect?

riaadevil.jpgI’ve already made my opinion of the RIAA known, but this latest development is truly unbelievable.

Apparently, the RIAA now feels that CDs you’ve ripped for your own personal use are unauthorized. What ever happened to the long-standing clause in copyright law that allows the holder of content to make up to five copies for personal use? What of the fact that it’s built right into the stupid DRM that the RIAA has forced Apple to implement on iTunes that you can put purchased music on up to five computers (and, implicitly at least, an unlimited number of iPods synced to those computers)?

It is patently absurd that any kind of legal case to this effect could be made in the current technological climate. According to the RIAA, just about everyone who owns an iPod (or a similar device) is a thief, even if they’ve paid for every single song on the device.

Well guess what: fuck you, RIAA. We are not thieves, we are your customers. But maybe we shouldn’t be.

OK, follow my train of thought here…

The other day, for reasons I’d best not get into, I was listening to the Steven Wright tracks from the Reservoir Dogs soundtrack. If you’ve seen the movie, you know that the soundtrack is interspersed with segments of deadpan comic Steven Wright‘s voice as a DJ on “KBILLY’s Super Sounds of the ’70s Weekend.” Listening to those tracks in sequence with absolutely no music in between them is a surreal experience.

In addition to the long-buried ’70s gems that made it onto the soundtrack, a slew of other songs did not appear, but did however get a mention from Steven Wright, tantalizingly conjuring a world beyond the details of the film, where a radio station that actually plays all of this crazy stuff exists! (Granted, this film predates the Jack FM phenomenon by a solid decade, but Jack rarely plays stuff this obscure.)

One of the titles Steven Wright mentions caught my attention: “Love Grows (Where My Rosemary Goes)” by Edison Lighthouse. (Anyone who knows me personally will know why that got my attention.) So I listened to a bit of it on iTunes, and it jogged a vague memory of this one-hit wonder from 1970. Then I headed over to YouTube, where I was delighted to find the music video:

Now many people of my generation or younger — or older for that matter — may not realize that they made music videos back in 1970 (and even earlier). I still have no idea where these things actually got played in a pre-MTV world. Of course, I don’t know where today’s music videos get played either, given that they sure as hell aren’t on MTV anymore.

Groovy.

Selling the Music Man!

Say it ain’t so! Well, it’s so. I have my Music Man StingRay 5 bass up for auction on eBay.

I love that bass, but I just can’t justify having a $1400 bass that sits in its case 99% of the time. Especially when I can sell it and use the money to buy both a bass and a guitar from Fender’s Mexican factory. And have almost half the money left over.

Say what you will about Ed Roman, but he had it right when he was talking about the likes of Fender and Gibson. (I think he was ripping more on Gibson, because of their obscenely high prices for U.S.-made guitars, but the message applies to Fender too.) Fender has 3 basic lines of products: their low-end beginner instruments made in China under the Squier brand, their “standard” line of Fender guitars made in Mexico, and the high-end stuff made in California. But the fact is, while there’s a huge chasm in quality between the Chinese Squiers and the Mexican Fenders, at about double the retail price, there’s very little difference between the very nice Mexican Fenders and the vastly overpriced American Fenders.

This was reinforced for me last weekend when I played my father-in-law’s Mexican-made Precision Bass. He bought it to play for the contemporary services at his church, based on my recommendation. I figured it would be a decent, reliable instrument, and it would only set him back 400 bucks. I had owned a Mexican-made Fender Jazz back in high school, and it was great until I decided to take it apart and muck around with it, and even after that it was still pretty decent. But I think the Mexican factory has made great strides; if I didn’t know better, I’d never guess that P-Bass wasn’t a U.S. model.

So it is, in a week or less the Music Man will be on its way to a new home, and I’ll be applying that cash towards…

Fender Standard Jazz Bass V

…and…

Fender Standard Stratocaster

…and while I’m at it, this, to (finally!) rip all of my LPs…

USB turntable