1 Replies - 2187 Views - Last Post: 02 June 2014 - 02:49 PM Rate Topic: -----

#1 _WolfShade_  Icon User is offline

  • D.I.C Head

Reputation: 3
  • View blog
  • Posts: 60
  • Joined: 12-May 14

How are multiple application.cfc's processed?

Posted 29 May 2014 - 02:14 PM

Hello,

How are multiple application.cfc's processed? For example, consider a file structure like so:
/wwwroot
--/admin
-- application.cfc
-- index.cfm
application.cfc
main.cfm

If I try to access /admin/index.cfm, does CF run ONLY the /admin/application.cfc before loading index.cfm? Or does CF run both wwwroot and admin application.cfc's?

I'm trying to access /admin/index.cfm - the /admin/application.cfc contains a CFINCLUDE to a file in the wwwroot called config.cfm that sets "current_user" to a value, but the /admin/index.cfm file errors saying that current_user isn't defined.

(Don't ask me.. I inherited this convoluted code. I'd love to scrap it and start from scratch, but we'll see.)

V/r,

^_^

Is This A Good Question/Topic? 0
  • +

Replies To: How are multiple application.cfc's processed?

#2 Craig328  Icon User is offline

  • I make this look good
  • member icon

Reputation: 2024
  • View blog
  • Posts: 3,609
  • Joined: 13-January 08

Re: How are multiple application.cfc's processed?

Posted 02 June 2014 - 02:49 PM

Huh. I have no idea. Truth be told, only one App.cfc is supposed to exist. I've never tried to use more than one on multiple levels.

I guess the best way to know would be to set the same variable in each App.cfc but with different values and then output the values along the way to see where it changes or even if it changes.

Lemme know...I'd be interested to see what it does.
Was This Post Helpful? 0
  • +
  • -

Page 1 of 1