Articles

Applying our Photoshop Thumbnail Script to Multiple Documents • May 25, 2009

A reader asked if there was a way to apply the Photoshop Thumbnail script I wrote to all open documents, so I figured I'd post it up here for everyone to see. read more »

Drupal: How to Remove the "not verified" Text from Comment Author Names • March 27, 2009

If you have comments activated on your Drupal site, and you allow non-members to leave comments, by default Drupal will append "(not verified)" to the names of people who leave comments and aren't logged in to your site. On many sites (like mine, for instance), people aren't even allowed to register accounts, meaning every comment has that pesky "(not verified)" text with it! I find that unfriendly, so here's how you can change that. read more »

Batch Image Resizing with Ruby and ImageMagick • March 10, 2009

A couple of days ago, I was working on an upcoming website that displays a hundred or so images of an artist's paintings. Each painting on the website will be represented in two sizes: a smaller view, and a "full-size" view. Also, for each painting there is associated information that needs to be displayed (title, size, medium, etc.). I certainly didn't want to do all that work by hand! So I wrote a script... read more »

Using the YUI Autocomplete Control as a Combo Box • January 22, 2009

Yesterday I found this article showing how to add a button to the Yahoo UI Autocomplete Control to make it behave like a combo box (i.e. all of the autocomplete's suggestions are listed in a dropdown when the button is clicked).

I was working on doing exactly this before I found the article, but had run into some buggy behavior in my implementation. I was doing it basically the same way this article suggests, having the button call the Autocomplete's sendQuery() method, passing it an empty string. But the button would only work the first time it was clicked; after that, clicking the button would return no results in the Autocomplete.

What this article pointed out to me is that the input element for the Autocomplete should have focus before you call sendQuery(), to ensure the query results in the dropdown being populated. This behavior certainly seems like a bug to me. read more »

Creating Image Thumbnails using PHP and ImageMagick • January 12, 2009

Last month I wrote a post on using Photoshop and Javascript to generate thumbnails. That's useful if you have to process a bunch of images for a website you're making, but what if you want to have a function on your website that accepts image uploads and then dynamically generates thumbnails? There's a lot that goes into that, but today I'm going to provide a basic PHP function (using ImageMagick) that gets the image processing part of the job done. read more »

Crucial Drupal Modules That I'm Just Finding Out About • December 17, 2008

Because of some recent need I had to do some search engine optimization (SEO) and spam blocking, I've come across some really great Drupal modules that I wanted to mention. A lot of you out there who build Drupal sites may already know about them, but here goes... read more »

Thumbnail Generation with Photoshop and JavaScript • December 15, 2008

A couple of weeks ago I wrote a post called Conditional Image Resizing with Photoshop and JavaScript that illustrated how to write a script to perform quick photo cleanup and resizing within a bounded area. Today I want to talk about a similar technique for generating thumbnail images. The fundamentals are the same, but the goal is slightly different. read more »

Conditional Image Resizing with Photoshop and JavaScript • November 28, 2008

Often I find myself having to do a lot of bulk image processing when I'm working on websites: resizing a bunch of pictures to a certain width or height, color adjustments, and sharpening, usually. It can be the most mind-numbing part of my work, and I'm always looking for ways to avoid that.

In Photoshop, you can use actions to help you automate a lot of repetitive work. However, the shortcoming I've found with actions is their lack of conditional behavior. For example, let's say I have a big batch of images, some portrait-oriented (taller than they are wide) and some landscape-oriented (vice versa), and I want to resize each of them to fit within a 500 x 500 pixel square. If the image is portrait-oriented, then I need to resize proportionally, setting the height to 500 pixels. If it's landscape-oriented, then I should resize proportionally with a 500 pixel width, instead of height. I've never found a good way to do this with a single action. But where actions fail, JavaScript comes to the rescue. read more »

I Thought That I Was Suddenly So Popular • August 31, 2008

Today, Google Analytics is telling me that, over the past two days, there's been a surge in traffic for sphericle.com, where I occasionally post music that I've made. The site usually gets a few hits per day, but on Friday it had 60 visitors, and Saturday saw 180! Great news, right? I wondered, how did this happen? Where are these visitors coming from? read more »

Development Hosting on Your Mac • November 5, 2007

I'd like to share how I go about hosting development versions of websites on my Apple laptop (it's a 12" Powerbook G4). These instructions should work for anyone running OS X 10.3 and up (probably even earlier versions, as well). I'm talking about the regular OS X, not OS X Server.

The goal for these instructions is to be able to run a local version of a website, under a domain name of your choosing. Incredibly useful for development. read more »

More Pages

Syndicate content