I was under the impression that throwing and catching an exception added some overhead. If not, then the function call isBase64() should work great. Thanks Jon/Dave...
Brook -----Original Message----- From: Dave Watts [mailto:[email protected]] Sent: April-22-11 9:37 AM To: cf-talk Subject: Re: check for a base64 encoded string > Reason being that throwing exceptions are expensive and also an ugly > way of programming an evaluation. IMHO.. Throwing exceptions isn't especially expensive, compared to whatever conditional logic they might otherwise replace. The ugliness thing is more a matter of the eye of the beholder, but there's nothing inherently wrong about using an exception to test failure. Dave Watts, CTO, Fig Leaf Software http://www.figleaf.com/ http://training.figleaf.com/ Fig Leaf Software is a Veteran-Owned Small Business (VOSB) on GSA Schedule, and provides the highest caliber vendor-authorized instruction at our training centers, online, or onsite. ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| Order the Adobe Coldfusion Anthology now! http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion Archive: http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:343904 Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm

