Adobe ColdFusion for the Web Developer
All these languages and their associated tools and frameworks are fine and respectable tools. However, for this article, Id like to focus on Adobe ColdFusion, an alternative language that actually predates most other web development languages. And, though ColdFusion predates many languages, it is far from being a lumbering dinosaur. In fact, ColdFusion has been whipped mercilessly by the forces of technological change and has evolved into a scrappy and tenacious survivor of a language.
ColdFusion? you may be asking. Isnt ColdFusion the old tag-based language from the 90s? Well, yes, ColdFusion dates from the mid 90s and it does primarily steer developers towards the use of a tag-based syntax thats not quite XML but should feel natural to anyone whos ever written an HTML document. Dont let the tag-based syntax distract you from the raw power the language provides.
ColdFusion has always focused on making complex and difficult tasks easy. The classic example of this is the ease of querying databases. In most languages you need to have several lines of code to establish a connection to a database server (more if youre using connection pooling), several lines to build your SQL statement, a couple lines to send the request, more to close the connection and then several more lines of code just to output data from the query into an HTML list However, early versions of ColdFusion consolidated most of this tedious process into one tag that wraps the SQL statement youre running and one tag that iterates over results.
Heres an example:
<cfquery name="users" datasource="myDatasource"> SELECT * FROM [User] ORDER BY name </cfquery> <ol> <cfoutput query="users"> <li><a href="mailto:#users.email#">#users.name#</a></li> </cfoutput> </ol>
You will note that the previous 11 lines of code were mostly SQL and HTML formatting to output an ordered list of users.
Every feature of ColdFusion has a similar modus-operandi: Make hard things as simple as they can possibly be without sacrificing power.
So, ColdFusion may have been useful in the twilight days of the Internet, but the world has moved on, right? Web applications do still rely on data from databases, but lets face it, they have many more demands placed on them now than they used to! A modern web application may need to talk to any number of databases and third party systems. It may need to do any number of complex activities such as image manipulation, data encryption, talk to mobile devices and much, much more.
ColdFusion has evolved from its tag-based scripting language past. Up until 2002, ColdFusion was based on C++. However, when the 6th major version of ColdFusion was released, ColdFusion MX, the language became Java-based, able to run in most Java server containers. The unexpected benefit of this is not only that ColdFusion can run pretty much anywhere that Java can, but that it also brings the richness of Java to a simple, friendly, dynamic, Object-Oriented-capable, tag-based language.
The net effect of this is that developers can more easily and productively build complex, enterprise applications. This fact is borne out by the locations where ColdFusion is most frequently used: Large, enterprise-class applications in the Government and major corporations.
The current released version of ColdFusion is 8. Version 9 is in the works. Each release has built on the successes of pervious versions. Since ColdFusion MX Macromedia, and now Adobe, have focused on adding as many useful features as conceivable to the language.
ColdFusion can talk to just about everything. It has support for all sorts of legacy connectivity such as COM and CORBA, but it can also talk to .NET assemblies and Java classes as well as too many others to list in this article. ColdFusion is designed to act as a sort of enterprise hub that can talk to everything under the sun.