On 31/12/2010 9:55 PM, Richard Steele wrote:
I'm testing some error checking stuff and don't understand why the
application.cfm doesn't abort before an error is found in a file.
Here's the application.cfm
cfabort
Here's the index.cfm
cftest
When the index.cfm is run, it shows the
The error you have there is a *compile time* *syntax* error, the code will
be compiled before the request is 'run' which is why you see the error. If
you change the code in index.cfm to cfset variable = undefinedVar /, the
code will compile fine and will then abort in your app.cfm as the error
Coldfusion will look for an application.cfm at the current folder
level and carry on up the directory tree until it finds one.
The first that it finds will override any further up the tree
On 11/9/06, John Cox [EMAIL PROTECTED] wrote:
One more newb question while I am at it. Does CF load
On 11/9/06, RichL [EMAIL PROTECTED] wrote:
Coldfusion will look for an application.cfm at the current folder
level and carry on up the directory tree until it finds one.
The first that it finds will override any further up the tree
Thanks, I understand that part. What I don't understand
]
Sent: Thursday, November 09, 2006 7:31 AM
To: CF-Talk
Subject: Re: application.cfm question
On 11/9/06, RichL [EMAIL PROTECTED] wrote:
Coldfusion will look for an application.cfm at the current folder
level and carry on up the directory tree until it finds one.
The first that it finds
Thanks Mike and Rich!
On 11/9/06, Dawson, Michael [EMAIL PROTECTED] wrote:
Application.cfm is called once per request. CFINCLUDE is not considered
to be a request.
However, the easiest way to test it is to add a CFMAIL or CFLOG tag to
the application.cfm file and then try it on an included
John
CF will just process the application.cfm of the original file not from
any directory where the included file comes from (if different from
the calling file)
e.g.
/dir1/
/dir1/dir2
- both dir1 and dir2 have their own application.cfm
If you have a file in dir1 and this includes a file in
couldn't you put a file in the root directory, set
CF_TEMPLATE_PATH to some
var, then include that file and call the var? you'd have to
strip out the
name of the file that sets the var though.
Yeah, that's a good idea. Didn't think about using a file other than
Application.cfm (doh!).
-- Original Message --
From: "river" [EMAIL PROTECTED]
/root/
/root/www/
/root/www/cgi-bin/
Now, let's say there are multiple application.cfm files, one in each
directory.
When CF server executes a template in /root/www/cgi-bin/ directory, does it
just
It looks in Current directory first... if it doesn't find one there, it
continues looking in every parent directory up to the root of the hard drive
that the template sits on...
If it finds one, it stops.
Heath
-Original Message-
From: river [mailto:[EMAIL PROTECTED]]
Sent: Tuesday,
ColdFusion first looks in the directory where the current template is being executed.
If no application.cfm file is found, it will traverse up the DIRECTORY tree, ALL THE
WAY to the root of the drive the application is on:
/root/www/cgi-bin/
/root/www/
/root/
-Andy
-Original
How does CF server look for application.cfm? For example,
let's say there
is a directory structure like this:
[ snip ]
It looks for an application.cfm file in the same directory as the template
that is being called.
If it can't find one, it goes up a directory and looks for one there. If
Cold Fusion Server will look for Application.cfm in the directory that the
template was called from and continue up the directory tree until it hits
the root. This is an example using NT and IIS.
So, If you call your application from
d:\inetpub\root\www\cgi-bin\, it will look here first then
CTED]]
Sent: Tuesday, February 20, 2001 8:35 AM
To: CF-Talk
Subject: RE: application.cfm question a n other question
How does CF server look for application.cfm? For example,
let's say there
is a directory structure like this:
[ snip ]
It looks for an application.cfm file in the
For to improve performance, should each directory have an application.cfm
file in it? Perhaps just containing an include of the one in the Root
Directory? Or is the overhead of searching upwards for the application.cfm
so small that it is not worth the effort?
Andy
One other thing I forgot to mention in my previous mail is that once it
finds the first application.cfm file during the search from the current
directory upwards, it stops. It does not search upwards for any more
application.cfm files.
So, if you have an application.cfm file in your root, and
in your subdirectory application.cfm did you name the application again?
CFAPPLICATION NAME="bugTracking"? since application variables belong to
specific applications, i think you need to specifically declare that it's
stil part of the same application. -emily
At 03:41 PM 4/25/2000 -0500, you
AM
To: [EMAIL PROTECTED]
Subject: RE: Application.cfm Question...
Application variables are only persistent because application.cfm file is
pre-pended to each and every template that is opened (not CFINCLUDED) by the
CF server.
The rule goes that the CF server will first search the current
For to improve performance, should each directory have an application.cfm
file in it? Perhaps just containing an include of the one in the Root
Directory? Or is the overhead of searching upwards for the application.cfm
so small that it is not worth the effort?
Andy
19 matches
Mail list logo