I had that very same idea, but personally think it would be far harder to do a JavaScript VM written in pure PHP than it is to do it this way around.
32 karma · joined July 27, 2011
For the HTML, it just checks a simple charset check and does the same as for images.
There are plenty of examples of the script embedded on the page though, and you can always download a copy from github and try it on your own page meanwhile.
For IE<9 the Flash option won't have to be the only option either, a server could be rendering the elements gathered from the users browser (in other words a canvas proxy for the canvas renderer).
In terms of my script, the aim is to try and get the compatibility down to FF3, IE6 (with non-canvas support through flashcanvas or server canvas), Opera (haven't looked much yet how old version would be able to support it), and Chrome.