Creates a ColdFusion image.
imageNew([source] [, width] [, height] [, imagetype] [, canvascolor])
→ returns any
rgb
argb
grayscale
black
Use the imageNew function to create a 200x200-pixel image in ARGB format.
<cfset myImage = imageNew("",200,200,"argb")>
<cfimage action="writeTobrowser" source="#myImage#">
This example shows how to create a ColdFusion image from a URL.
<cfset myImage = imageNew("http://www.google.com/images/logo_sm.gif")>
<cfset imageWrite(myImage,"google_via_imagenew.png")>
<img src="google_via_imagenew.png">
Signup for cfbreak
to stay updated on the latest news from the ColdFusion / CFML community. One email, every friday.