[clue-tech] Bandwidth "stealing"

Jed S. Baer cluemail at jbaer.cotse.net
Sun Mar 23 16:27:34 MDT 2008


On Sun, 23 Mar 2008 18:08:56 -0400
Angelo Bertolli wrote:

> is there a way to overlay my domain name in the corner of 
> images that people hotlink from my site?

Yes.

At least a couple things come to mind. 1st, you'd need to do something
like use mod_rewrite to have Apache service the request via a script,
passing the image name as a parameter.

Then, use either ImageMagick, or PHP with the GD library to watermark the
image on the fly, and return that, making sure to set the correct mime
type. I'm not sure if you could do this by invoking one of the
ImageMagick commands directly, due to the mime type issue.

If you wanted to get fancy, you could cache the watermarked images, and
then have your script check the cache first, before spending processing
cycles.

jed


More information about the clue-tech mailing list