Developing Web Applications with ColdFusion
|
|
Chapter 12 : Using the Application Framework
|
Creating the Application.cfm File
The special application-wide page called Application.cfm
defines application-level settings and functions such as:
- The application name
- Client state management options
- Application and session variables
- Default variables
- Custom error pages
- Data sources
- Default style settings
- Exclusive locks
- Other application-level constants
Note |
Because UNIX is case sensitive, the application framework file must be
spelled with an initial capital, Application.cfm , for applications that run
on UNIX platforms.
|
Naming the application
In ColdFusion, you define an application by giving it a name using the CFAPPLICATION tag. By using the same application name in a CFAPPLICATION tag, you define a set of pages as being part of the same logical application.
Note |
The value you set for the NAME attribute in CFAPPLICATION is limited to
64 characters.
|
 |
To name the application:
|
- Open Studio and create a new file.
- Modify the file so that it appears as follows:
<!--- This example illustrates CFAPPLICATION --->
<!--- Name the application --->
<CFAPPLICATION NAME="SearchApp">
- Save the file as
Application.cfm
in the root directory of your application framework.
Copyright © 1999, Allaire Corporation. All rights reserved.
|
|