Well I really like the onApplicationStart/End handler, but we have that worked out already using the structkeyexists method. The main feature I'm looking to use at the moment is onError, the cferror tag doesn't allow any real coldfusion code to be ran on the error page and I'd like to have cfdumps of all my scopes and the exception e- mailed to me.

Would it be possible to call the default onrequest method somehow? I tried using super, but that did not work...

Thanks for the tips, I appreciate it!
Kenton


On Jun 22, 2006, at 12:10 PM, Dave Watts wrote:

This might be a question that can't doesn't have an answer I
like, but I'd like to make sure I'm not missing any obvious options.

We have a very large coldfusion application built long ago
that I would like to move over to an Application.cfc file.
This page has a very complex application.cfm file which I
thought I could pretty much copy into onRequestStart.
Unfortunately the variables on this application.cfm are
unscoped, so they don't reach the main pages.
Also the pages that call these variables are also unscoped.

I thought by putting them in the request or variables scope
on the app.cfc would fix it but apparently request isn't
searched when looking for an unscoped variable, and the
variables scope does not reach to the calling page,

The way I was able to work around it was putting all the code
into onRequest, but then I found out that this breaks
webservices and flash remoting. I really don't know where to
go from here, and scoping the variables on over 2000 pages or
so isn't really an option, am I forced to continue to use
application.cfm? I've seen mentions of deleting the onrequest
scope on webservice cfcs, but I don't particularly like that
option either.

This is kind of a pain. One workaround might be to use inheritance - you could have three Application.cfc files, essentially. The core one would not define an onRequest event. The one used by most of your application would extend the core one, define onRequest, and define the local page variables you want. The one used by your web services would not define onRequest.

But, honestly, I'd probably stick with Application.cfm for existing
applications, unless there's some specific feature of Application.cfc that you want to employ. The compelling thing about Application.cfc for me is the
onSessionEnd and onApplicationEnd event handlers.

Dave Watts, CTO, Fig Leaf Software
http://www.figleaf.com/

Fig Leaf Software provides the highest caliber vendor-authorized
instruction at our training centers in Washington DC, Atlanta,
Chicago, Baltimore, Northern Virginia, or on-site at your location.
Visit http://training.figleaf.com/ for more information!



----------------------------------------------------------
You are subscribed to cfcdev. To unsubscribe, send an email to [email protected] with the words 'unsubscribe cfcdev' as the subject of the email.

CFCDev is run by CFCZone (www.cfczone.org) and supported by CFXHosting (www.cfxhosting.com).

An archive of the CFCDev list is available at www.mail-archive.com/ [email protected]





----------------------------------------------------------
You are subscribed to cfcdev. To unsubscribe, send an email to 
[email protected] with the words 'unsubscribe cfcdev' as the subject of the 
email.

CFCDev is run by CFCZone (www.cfczone.org) and supported by CFXHosting 
(www.cfxhosting.com).

An archive of the CFCDev list is available at 
www.mail-archive.com/[email protected]


Reply via email to