1) When the FW/1 request variables are created -- I know this has come
up before, but I was first trying to say something like this in the
pseudo-constructor of my Application.cfc:
if(request.action EQ 'admin.resetapp')
variables.framework.reloadApplicationOnEveryRequest = true;
Then I tried:
if(getFullyQualifiedAction() EQ 'admin........
Of course, neither work because FW/1 hasn't yet set up the request
variables at that point.
Is this still something on the table for version 2??
2) When generating the link to reset the app I found myself wishing I
could access variables.framework.reload and variables.framework.password
in my controller, but near as I can tell there's no clean way to do that.
Am I crazy to want to do these things?
I second this idea.
I currently use two methods.
1. Do a cfhttp call to the application passing in the "reload=true"
2. I have this code block in my Application.cfc in the setupRequest()
method (but this would log you out of the admin)
<cfif IsDefined("url.restartapp") AND URL.restartapp EQ "true">
<cfset StructClear(SESSION) />
<cfset StructClear(Application) />
<cfset Application.ApplicationName = "appname">
<cflocation addtoken="no" url="index.cfm">
</cfif>
Nothing has run inside FW/1 by the time your pseudo-constructor runs
in Application.cfc so that simply is not possible.
> 2) When generating the link to reset the app I found myself wishing I could
> access variables.framework.reload and variables.framework.password in my
> controller, but near as I can tell there's no clean way to do that.
Sure there is! getConfig() (or is it getConfiguration()? I'm on my
netbook and don't have the code open right now).
> Am I crazy to want to do these things?
Open a ticket for the first one. It may simply not be possible but
I'll look at it.
--
Sean A Corfield -- (904) 302-SEAN
Railo Technologies, Inc. -- http://getrailo.com/
An Architect's View -- http://corfield.org/
"If you're not annoying somebody, you're not really alive."
-- Margaret Atwood