Create your own electronic signature (Flex-based or HTML5-based) In an updated example of a technique that combines an AS3 PNG encoder, an open-source utility (KVEC), the Apache Batik project, and of course, ColdFusion 9, you can create your very own electronic signature. You can also try the new HTML5 version. Flex-based version : The electronic signature you create, by dragging your mouse across the signature canvas to, in effect, sign your 'John Hancock', works like this: - The signature drawing is passed as binary data to a ColdFusion CFC function that saves the PNG to the ColdFusion server's file system.
- Next, leveraging an open source tool, KVEC, the PNG, created in step one, is passed to another CFC function that converts the PNG to a SVG file.
- Next, the SVG is passed to a CFC function that completes the final conversion to a PDF file, using the Apache Batik project's batik-rasterizer.jar.
- Next, leveraging the ColdFusion 9 (available in CF 8 too) <cfzip> tag, a CFC function creates a zip archive of the PNG, the SVG, and the PDF files of the signature just created.
- Finally, to save on disk space, a final CFC function is called to delete the PNG and SVG files (once the PDF and zip archive are safely created).
Click to create your own electronic signature with the Flex-based version. HTML5-based version : The electronic signature you create, by dragging your mouse across the HTML5 canvas to, in effect, sign your 'John Hancock', works like this: - The signature drawing is converted to a JSON array of points, via a modified Thomas J. Bradley's Signature Pad, collected, via James Moberg's sigJsonToImage ColdFusion UDF, and passed to a function in the UDF that saves the PNG (a raster-based graphic) to the ColdFusion server's file system.
- Next, leveraging an open source tool, KVEC, the PNG, created in step one, is passed to CFML that converts the PNG to a SVG file.
- Next, the SVG is passed to CFML that completes the final conversion to a PDF file, using the Apache Batik project's batik-rasterizer.jar.
- Next, leveraging the ColdFusion 9 (available in CF 8 too) <cfzip> tag, and more CFML that creates a zip archive of the PNG, the SVG, and the PDF files of the signature just created.
- Finally, to save on disk space, final CFML is used to delete the PNG and SVG files (once the PDF and zip archive are safely created).
Click to create your own electronic signature with the HTML5 version. Tip Jar: |