Skip to main content
Participant
October 24, 2006
Question

include root application.cfm in Application.cfc

  • October 24, 2006
  • 1 reply
  • 424 views
I created a coldfusion app which has "Application.cfc" file. I want to integrate this application
to the company's main application which has "Application.cfm" in the web root folder.
The question is how can I access Application.cfm variables (like loginID)

can i use <cfinclude template="../application.cfm"> in OnApplicationStart??
the file structure is as shown below

WWWROOT(folder)
.................... Application.cfm
.....................MYAPP(folder)
...............................Application.cfc
................................page1.cfm

How can page1.cfm see the variables in Application.cfm?

Thanks

This topic has been closed for replies.

1 reply

October 24, 2006
You should create an OnRequest method in your Application.cfc and the include the parent Application.cfm. Then you'll need to include the argument.