if i used htaccess i would simply link to
http://example.com/example/anything.html and it would create an image , write the words "anything" on it , link to it and display the image
in the example i just posted i skippped the htaccess part ( you dont have to use it either its just a more clever way of doing it )