soltice wrote in php

Secure words

On a lot of websites now, especially on member registration pages, there's a part at the bottom of the page that displays a graphic and a text field. The graphic contains either a word or number that (supposedly) cannot be read by an OCR. The word or number is to be entered into the text field for confimation that you are in fact, human.

My question is, how does one generate that graphic? I have a few ideas, but I have no idea if PHP is capable of executing them...