User Guide

The HTTP API 45
MMHttp.clearTemp()
Description
This function deletes all the files in the Configuration/Temp folder, which is located in the
Dreamweaver application folder.
Arguments
None.
Returns
Nothing.
Example
The following code, when saved in a file within the Configuration/Shutdown folder, removes all
the files from the Configuration/Temp folder when the user quits Dreamweaver:
<html>
<head>
<title>Clean Up Temp Files on Shutdown</title>
</head>
<body onLoad="MMHttp.clearTemp()">
</body>
</html>
MMHttp.getFile()
Description
This function gets the file at the specified URL and saves it in the Configuration/Temp folder,
which is located in the Dreamweaver application folder. Dreamweaver automatically creates
subfolders that mimic the folder structure of the server; for example, if the specified file is at
www.dreamcentral.com/people/index.html, Dreamweaver stores the index.html file in the People
folder inside the www.dreamcentral.com folder.
Arguments
URL,
{prompt}, {saveURL}, {titleBarLabel}
The URL argument is an absolute URL on a web server; if http:// is omitted from the URL,
Dreamweaver assumes HTTP protocol.
The prompt argument, which is optional, is a Boolean value that specifies whether to prompt
the user to save the file. If saveURL is outside the Configuration/Temp folder, a prompt value
of
false is ignored for security reasons.
The saveURL argument, which is optional, is the location on the user’s hard disk where the file
should be saved, which is expressed as a file:// URL. If prompt is a true value or saveURL is
outside the Configuration/Temp folder, the user can override
saveURL in the Save dialog box.
The titleBarLabel argument, which is optional, is the label that should appear in the title
bar of the Save dialog box.
000_DW_API_Print.book Page 45 Wednesday, August 20, 2003 9:14 AM