Today ColdFusion moved into the next stage of its life and became a teenager, hopefully not a precocious one!

Happy 13th Birthday ColdFusion.

Adobe ColdFusion has had a long and illustrious life. The first version of ColdFusion–written almost entirely by one person, JJ Allaire and then called “Cold Fusion”–was released in 1995. This first version, although revolutionising how web applications were built, was primitive by modern standards, doing little more than database access.

Although originally built in Visual C++, Allaire, around 1999, took the decision to rewrite the entire ColdFusion engine in Java–a project named “Neo”–which would allow for greater portability among different platforms. The rewrite, released under the monicker MX 6, would prove to be somewhat problematic and a wholescale update to the version resulted.

In 2001 Allaire was acquired by Macromedia. This union brought with it the integration of Macromedia’s Flash platform via Flash Remoting; a huge step towards rich Internet applications.

In 2005 it was the turn of Macromedia to be acquired and they merged with Adobe. A period of instability in the ColdFusion world resulted, brought about by the knowledge that Adobe was a company that developed tools, not programming languages. However, following a successful release of ColdFusion 8 in 2007 and the announcement that a version 9 would be developed, code-named “Centaur”, fears about ColdFusion’s future have subsided–albeit the continued debate over “ColdFusion is Dead” remains boiling in the background.

The primary distinguishing feature of ColdFusion is its associated scripting language, ColdFusion Markup Language (CFML), which compares favourably to its rivals, JSP, ASP.NET, or PHP and resembles HTML in syntax. “ColdFusion” is often used synonymously with “CFML”, but it should be noted that there are additional CFML application servers besides ColdFusion, and that ColdFusion supports programming languages other than CFML, such as server-side Actionscript and embedded scripts that can be written in a JavaScript-like language, known as CFScript. Adobe ColdFusion also includes native support for Flex, PDF, Verity and the embedded Derby database amongst a host of other features.

ColdFusion 9 is set to be an exciting release, much like its predecessor, with more features added to the core tag set, whilst also integrating other technologies such AIR and Hibernate.

Exciting times lay ahead. Let’s hope Adobe takes full advantage with such a fine product.

See Also:

The Adobe ColdFusion 8 Developer Exam arrived earlier this year and it is about time I took it. But like Ben Nadel, the exam scares me! Why? Because there is so much more to know. With the introduction of new AJAX tags, native JSON support, .NET integration, image manipulation, threading, interfaces, not to mention full PDF integration, the presentation builder and across the board enhancements, there are a lot of new things to know.

If it wasn’t for the fact that I am also an Adobe Certified Trainer, I would probably shy away from taking the exam, since, apart from showing that I have gained an Advanced level of knowledge of what’s available in the language/application, is it really relevant?

Now for the moan…

I like to prepare for exams properly. I studied hard for the CFMX6.1 and CFMX7 exams because I wanted to achieve the best result I possibly could. I don’t much like the stigma of mediocrity, so I try hard. But with the advent of the ColdFusion 8 exam, Adobe aren’t making life any easier and this isn’t because of the increased number of features. It’s because they are not supporting their exam with the appropriate study material.

In the past, Ben Forta had been commissioned to create the official developer study guide. However, according to Ben, this appears no longer to be the case (at least for now).

It beggars belief that Adobe release a product, then release a related exam, but do not have the will to produce a study guide. Yes we have the Web Application Construction Kit and Livedocs, but for me, they are either not succinct enough or not available in print. It makes it tough to study.

Clearly there is a cost issue, but Adobe Publishing can be smarter these days with their print-runs. Indeed they could even allow developers to choose between a print and PDF versions, much like Manning and many other publishers.

Perhaps Ben is busy. Surely not! But if it is the case, I’m sure there are a number of his peers that could take up the mantle. Cue…

A ray of hope…

There is a small ray of hope. There is likely to be an updated version of the popular CFMX Exam Buster by CentraSoft. Brian Simmons is working hard on the latest version.

I recently taught a Fast Track to ColdFusion 7 (FTCF7) course and what struck me was the liberal use of the isDefined() function throughout the course material. Now, I confess, I have used the function many times in the past, but now more commonly use the structKeyExists() function. So why does Macromedia and now Adobe, still highlight the isDefined() function when, in my opinion, structKeyExists() is more efficient?

First we need to define what each one does:

IsDefined() evaluates a string value to determine whether the variable named in it exists.

StructKeyExists() determines whether a specific key is present in a structure.

On the Adobe Livedocs website, the documentation highlights the fact that the two functions are interchangeable in several situations, e.g. whenever a structure (i.e. associative array) is used. Now, almost everything is a structure, so that doesn’t help.

IsDefined() checks not just if a variable exists, but if it is also syntactically correct. This clearly has runtime implications. That is why, when dealing with structures you should avoid isDefined() in favour of structKeyExists().

I hope the FTCF8 course moves forward and ditches the liberal use of isDefined() and introduces more examples of alternative functions such as structKeyExists(). All too often I see examples which appear to be the path of least resistence, but not best practice.

Shall I mention the incomplete/non-functioning code examples in the FTCF7 course … !?! That’s another story.

I’m a ColdFusion freelance developer and as can often happen, I end up using a spare machine sitting in the corner of a room. Being relegated to the “dunce’s corner” is bad enough, but commonly the ColdFusion password has also been forgotten. This happened to me just the other day. So, how do we go about resetting the password?

Back in the ColdFusion 5 days you could edit the registry value:

HKEY_LOCAL_MACHINE\software\allaire\coldfusion\currentversion\server

set UseAdminPassword to 0 and restart the ColdFusion service, not forgetting to set a new password afterwards, especially if you’re on a production server.

Now with ColdFusion MX and MX7, you can’t but the process is not too tricky either. In fact there are two methods available to you.

First method:

You need to locate the password.properties file in the C:\CFusionMX7\lib\ directory. Opening the file, you will be presented with something much like this:

#Tue Apr 24 10:41:59 BST 2007
rdspassword=09GTH9 8O&>36& \\Q>[K\=XP \n
password=5BAA61E4C9B93F3F0682250B6CF8331B7EE68FD8
encrypted=true

Change the password to an alpha-numeric string of your choice and encrypted to false, much like this:

#Tue Apr 24 10:41:59 BST 2007
rdspassword=09GTH9 8O&>36& \\Q>[K\=XP \n
password=L3tM31n
encrypted=false

save the file and restart the ColdFusion service, you will be able to get into the ColdFusion Administrator with your chosen password.

Second method:

Locate the neo-security.xml file in the C:\CFusionMX7\lib\ directory. Opening the file you will be presented with a WDDX packet containing ColdFusion server configuration settings. The lines you will need to edit are the following:

<var name=’admin.security.enabled’>
<boolean value=’true’/>
</var>

Change the boolean value to false, like this:

<var name=’admin.security.enabled’>
<boolean value=’false’/>
</var>

save and restart the ColdFusion service. You can now log into the ColdFusion Adminsitrator without a password.

NB It is always recommended that a password be used for production systems.