Resizing images on the fly with Coldfusion is easy. While it does put a strain on your server you may have a valid reason for wanting to do this ie not allowing someone to hot link an image?
This works in Coldfusion 8 and Railo ( probably Open BD )
Here is the code:
The temporary files end up here: {cf8root}\tmpCache\CFFileServlet\_cf_image and they are cleared after 5 mins on the next image resize. Railo links the images back to {webContextroot}/WEB-INF/railo/temp/graph/
Here is a demo:
Coldfusion http://cf9.kukiel.net/demos/onflyimageresize/
Railo http://railo.kukiel.net/blog/onflyimageresize/
2 comments: