Short answer is, it’s difficult if you want to inherit the methods of the root 
folder Application.cfc.  Coldfusion allows for one Application.cfc to extend 
another, but only if the inherited Application.cfc isn’t in the root directory 
of the site or has a mapping in the CF Admin ( i.e. -you can’t use 
extends=“Application.cfc”) or it throws an error, thinking it’s calling itself. 
 

That said, you can either create a mapping, make your inherited Application.cfc 
part of a subdirectory so CF doesn’t get confused or use inheritance from 
another component, along with the SUPER scope to do what you want to do.  Ben 
Nadel has a nice tutorial on the subject:

http://www.bennadel.com/blog/1179-Ask-Ben-Extending-Application-cfc-And-OnRequestStart-With-SUPER.htm

HTH,

Jon



On Nov 25, 2013, at 1:30 PM, Eric Roberts <ow...@threeravensconsulting.com> 
wrote:

> 
> Here's the background...
> 
> We have all of our requests going through the index.cfm in the root and 
> depending on variable values, they get directed, via cfincludes, to 
> subfolders.
> 
> My question is how do I get the application.cfc in the subfolder to run?  The 
> application.cfc in the root is getting run, but it appears that the one in 
> the subfolder is not.  Each sub-folder contains a separate application with a 
> unique name and the application.cfc has application specific variables in it. 
>  The application.cfc in the subfolder is set to extend the one in the root.
> 
> Eric 
> 
> 

~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~|
Order the Adobe Coldfusion Anthology now!
http://www.amazon.com/Adobe-Coldfusion-Anthology/dp/1430272155/?tag=houseoffusion
Archive: 
http://www.houseoffusion.com/groups/cf-talk/message.cfm/messageid:357133
Subscription: http://www.houseoffusion.com/groups/cf-talk/subscribe.cfm
Unsubscribe: http://www.houseoffusion.com/groups/cf-talk/unsubscribe.cfm

Reply via email to