I've done some dabbling in PHP's GD library (the image
manipulation extension of PHP).
What I have done in the past is create a separate php file
just for the image output. I then pass in the parameters needed to
create the image in the image request. So as an example, I'd send
the image request like so: