in reply to How do you make on the fly images?

Consider accessibility when doing this. The W3C has a discussion document about using mangled images and suggests a few alternatives: Logic, word, or trivia questions, sound, credit-card checks. All of these have difficulties at least as great as with the images, but could get one thinking.

Also see the links at the bottom of that document, especially the CAPTCHA project