Category Archives: ColdFusion

Getting a file’s timestamp using ColdFusion

Finding a file’s date/time is now quite easy in ColdFusion by simply making use of the underlying Java File and Date objects. A bit of code … <cfset filePath = "datamyfile.txt"> <cfset fileObj = createObject("java","java.io.File").init(expandPath(filePath))> <cfset fileDate = createObject("java","java.util.Date").init(fileObj.lastModified())> At this point the fileDate variable contains a normal ColdFusion date. Couple of notes: The java.io.File [...]
Posted in ColdFusion | Tagged , | Comments closed

Choosing ColdFusion Development Environment Tools

There are a few choices in tools for ColdFusion development in a Windows environment. I have found the following set of tools to work well for me. Editor: Eclipse with CFEclipse Plugin I have tried out a couple of editors – CFStudio, HomeSite, Dreamweaver then Eclipse. Dreamweaver is still number 1 for me for CSS [...]
Posted in ColdFusion | Tagged , , , , | Comments closed

Writing Your Own Simple MVC Framework in ColdFusion

There are a few ColdFusion frameworks around but unfortunately it may not always be possible to use them – such as in a shared hosting environment. See my previous post about ColdFusion mappings which discusses why. The following notes describe how a simple event driven framework might be written. This is intended to be a [...]
Posted in ColdFusion | Tagged , | Comments closed

ColdFusion Mappings and Components

When I first started working with ColdFusion mappings I was confused about how ColdFusion components were found. In addition, I did not understand the relationship between component creation and mappings and custom tag paths. After some research I found the following surprising results. When you create a new Component using createObject() ColdFusion searches for the [...]
Posted in ColdFusion | Tagged , | Comments closed