Friday, June 15, 2007

onMissingTemplate

on MissingTemplate, The Latest from Tom Jordahl

Hi Folks,

There was a recent thread on the behavior of the Application.cfc method
"onMissingTemplate".  Currently the RC behavior is:
If the file requested doesn't exists on disk,
  - Create Appication scope
  - Create Session scope
  - Fire onMissingTemplate if present

I have just changed it to this:
If onMissingTemplate function is present in Application.cfc AND the file
requested doesn't exists on disk,
- Create Application scope & Fire onApplicationStart (if needed)
- Create Session scope & Fire onSessionStart (if needed)
- Fire onMissingTemplate, which has access to both session & application
scope.

I believe this takes care of the issues raised by RayC. and  Michael D. on
other threads as well as preventing the creation of 'extra' sessions when
you don't have an onMissingTemplate function.

Did I get it right?  :-)

--
Tom Jordahl
Adobe ColdFusion Team
 

No comments:

Post a Comment