MACROMEDIA COLDFUSION 4.5-DEVELOPING WEB Develop Manual page 259

Developing web applications with coldfusion
Table of Contents

Advertisement

Chapter 15: Interacting with Remote Servers
Code Review
Code
<CFHTTP METHOD="Get"
URL="http://www.allaire.com/index.cfm"
RESOLVEURL="Yes">
<CFOUTPUT>
#CFHTTP.FileContent# <BR>
</CFOUTPUT>
To get a Web page and save it in a file:
1.
Open a new file in Studio.
2.
Modify the file so that it appears as follows:
<CFHTTP
3.
Change the path from
4.
Save the file as
Code Review
Code
<CFHTTP
METHOD = "get"
URL="http://www.allaire.com/index.cfm"
PATH="c:\mine"
FILE="allaireindex.cfm">
To get a binary file and save it:
1.
Open a new file in Studio.
2.
Modify the file so that it appears as follows:
METHOD = "get"
URL="http://www.allaire.com/index.cfm"
PATH="c:\mine"
FILE="allaireindex.cfm">
c:\mine
savewebpage.cfm
Description
Get the page specified in the
URL and make the links
absolute instead of relative..
Display the page, which is
stored in the variable
CFHTTP.FileContent
browser.
to point to a path on your hard drive.
and view it in your browser.
Description
Get the page specified in the
URL and save it in the file
specified in PATH and FILE.
Note that when the PATH and
FILE attributes are used, the
RESOLVEURL attribute is
ignored, even if present.
233
, in the

Advertisement

Table of Contents
loading
Need help?

Need help?

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

This manual is also suitable for:

Coldfusion 4.5

Table of Contents