Saving Application Pages; Viewing Application Pages - MACROMEDIA COLDFUSION 5-DEVELOPING Develop Manual

Table of Contents

Advertisement

Working with ColdFusion Application Pages

Saving application pages

Instead of saving pages with an htm or html file extension, you save ColdFusion
application pages with a cfm or cfml extension. By default, the Web server knows to
pass a page that contains a cfm extension to the ColdFusion Server when it is
requested by a browser.
Save ColdFusion application pages underneath the Web root or another Web server
mapping so that the Web server can publish these pages to the Internet. For example,
you can create a directory
To save the page:
1
2

Viewing application pages

You view the application page on the Web server to ensure that the code is working as
expected. Presently, your page is very simple. But, as you add more code, you will
want to ensure that the page continues to work.
To view the page in a local browser:
1
2
<!--- Set all variables --->
<cfset department="Sales">
<!--- Display results --->
<cfoutput>
I'd like to talk to someone in #Department#.
</cfoutput>
</body>
</html>
Select File > Save.
Save your page as calldept.cfm in myapps under the Web root directory.
For example, the directory path on your machine might be:
(on Windows NT) c:\inetpub\wwwroot\myapps
(on UNIX) <mywebserverdocroot>/myapps
Open a Web browser on your local machine and enter the following URL:
http://127.0.0.1/myapps/calldept.cfm
where 127.0.0.1 refers to the localhost and is only valid when you are viewing
pages locally.
Use the Web browser facility that allows you to view a page's source code to
examine the code that the browser uses for rendering.
Note that only HTML and text is returned to the browser.
and save your practice pages there.
myapps
11

Advertisement

Table of Contents
loading
Need help?

Need help?

Do you have a question about the COLDFUSION 5-DEVELOPING and is the answer not in the manual?

Questions and answers

Subscribe to Our Youtube Channel

This manual is also suitable for:

Coldfusion 5

Table of Contents