So we know that GD2 has the power of image processing on the server side. This combined with refreshless page loads, the ability to deliver eye-candy with the click of a button, could probably render some cool results? Let's give it a shot ^^
What I'll try to show here is the following:
Set up a "base" image and show it in the browser
Allow for user input, text, to be submitted
Let server process the image on submit, to apply text to the image
Have AJAX (powered by SAJAX) deliver the result back by javascript callback
There are probably easier ways to apply the same effect we'll be creating. We do this because we know that what is shown is a "real" image, processed and put together by GD2. It creates an actual image wich we could store, edit or do whatever we want with - it's no cheap javascript layered effect ^^
Below, the application. Below that, the magic piece by piece, explained
TOP OF FILE : <? require("lib/Sajax.php");
//serverside image process function processImage($text){ $im = imagecreatefrompng( '/xxx/yyyy/zzz/httpd.www/port80/images/diver.png');