Skip to main content
Inspiring
November 16, 2010
Question

application.cfc versus application.cfm

  • November 16, 2010
  • 3 replies
  • 1340 views

HI I have application.cfc and applicaiton.cfm in one folder. I defined same global varibales in both files with different values. I am using same global  variables in my cfml files. When I call my cfml page which values will dispaly in my page?

Advance Thxs

This topic has been closed for replies.

3 replies

Community Expert
November 18, 2010

Daverms is right. But Owain and Adam are also right - you should test these things to find out. It's a much better way to learn, it actually takes less time than to wait for an answer, and you're more likely to remember the answer.

Dave Watts, CTO, Fig Leaf Software

http://www.figleaf.com/

http://training.figleaf.com/

Fig Leaf Software is a Veteran-Owned Small Business (VOSB) on

GSA Schedule, and provides the highest caliber vendor-authorized

instruction at our training centers, online, or onsite.

Read this before you post:

http://forums.adobe.com/thread/607238

Dave Watts, Eidolon LLC
Inspiring
November 16, 2010

What values did you see when you ran a page?

Inspiring
November 16, 2010

What values did you see when you ran a page?

Dan makes a good point.  Most oftent he fastest way to test these things is to just try it.  What's the harm in just giving something a go and see what happens?  It's the best way to learn things.  Asking people the answer is not a good way to learn things.

--

Adam

Owainnorth
Inspiring
November 17, 2010

Oh man, that sounds like the kind of stupid question you'd get in the CF exam, to which you'd be looking for the evasive answer e) No-one knows, it's a stupid question, if I ever wanted to know I'd just try it.

Seriously, you could've tried it yourself in the time it takes the Adobe forums to load.

I'm about to go make myself a coffee, can someone let me know in advance whether or not I'll have to top up the kettle please.

Inspiring
November 16, 2010

Even if you have both Application.cfm and Application.cfc files in your project folder, only the "Application.cfc" will be processed and you will have access to only those global variables that you define as part of your Application.cfc template.

HTH