New cfcUnit release coming soon.
After taking a look at the cfcUnit code with CFMX 7, I have discovered some things that have changed from CFMX 6.1 to 7. Basically, you can no longer directly instantiate the class "WEB-INF.cftags.component", and I did this in a number of places in the framework's self tests. There are also some issues with the displayed results, so I am going to revisit the style information.
I suppose this will be a good time to also go ahead and make it offically a 1.0 release (which it really has been for almost a year).
CFFORMs Galore!
Over the last month, I have seen a whole bunch of postings with tips on how to use the new CFFORM tags. You know, all that stuff that's not in the documentation. Anyhow, I've been collecting those links as they were published, and I figured now that I have quite a few I would go ahead and share them as a single list.
Here they are:
- Working with Required Checkboxes in CFFORM
- CFForm Tip
- Issue with CFGRID in Flash Forms
- Issue with empty strings and Flash Forms
- Validating "Pages" in CFFORM (2)
- Validating "Pages" in CFFORM
- CFForm Tips (3)
- CFForm Tips (2)
- CFForm Tips
- Warning About Flash Forms
- Aligning Buttons in CFForm
- Creating Better Forms Faster with ColdFusion MX 7
- Filtering records on a cfform grid
- OnLoad event in ColdFusion Flash Forms Part I
- OnLoad event in ColdFusion Flash Forms Part II
- Filtering a list as you type in a ColFusion Flash Form - AS Fusion
- Adding a Filter to your flash form in CFMX 7
- Filter Your CFGRID Revisited
- Dependent CFSELECTS using CF7's Flashforms
- Thinking About XML Forms in CFMX 7
- Flash form BG color
- The Power of XForms (in ColdFusion)
- Bug in CFMX7 XSL and CFSELECT
- Filtering a grid as you type in a cfform
- Programmatically Changing Flash Form Calendar Selectable Ranges
- Loading Images in a cfform
Session is invalid...a solution.
There has been much discussion about a very annoying bug and how it has afflicted the customers at CrystalTech that have sites running on ColdFusion 7. For those of you who don't know what I am talking about, those in the loop know this as "Session is invalid". Anyhow, it has something to do with J2EE sessions getting out of synch with the ColdFusion sessions...
Anyhow, there are solutions out there for use in Application.cfm files, but there aren't any for Application.cfc files. Well, I think I have a solution that works using the onError() method in Application.cfc. I'd be curious to see if this works for anyone else. Let me know.
Well here it is:
<cffunction name="onError" returntype="void" access="public" hint="">
<cfargument name="exception" type="any" required="true" hint=""/>
<cfargument name="eventName" type="string" required="true" hint=""/>
<!--- --->
<cfset var expirationDateTime = "">
<cfset var redirectUrl= "/index.cfm">
<cfif arguments.exception.message IS "Session is invalid" AND
IsDefined("cookie.jsessionid")>
<cfset expirationDateTime = GetHttpTimeString(DateAdd("d", -1, Now()))>
<cfheader statuscode="302" statustext="Moved Temporarily"/>
<cfheader name="location" value="#redirectUrl#"/>
<cfheader name="Set-Cookie"
value="JSESSIONID=;expires=#expirationDateTime#;path=/"/>
</cfif>
</cffuntion>