When you define an ASP site in Dreamweaver, you can specify the location of the site files on your hard disk as well as on a remote server running ASP (for users). You can also specify the method for moving files and folders between the two locations. However, if you're only interested in setting up a personal development environment, and ASP is running on your local computer, then you don't need to specify a remote server for your site yet.
Topics covered in this section:
To specify your working folder:
In Dreamweaver, select Site > Manage Sites. In the Manage Sites dialog box, click the New button, and then select Site.
The Site Definition dialog box appears.
Click the folder icon next to the Local Root Folder text box and browse to the folder where you want to store working files on your hard disk. You can use the dialog box to create a folder and then select it. For example, you can create one of the following folders:
Windows: ...\My Documents\Dev\MyWebApp
Macintosh: .../Documents/Dev/MyWebApp
Leave the Site Definition dialog box open. You will specify your testing or production server next.
In this section, you define the location for the files on your testing or production server, as well as the method for transfering the files to and from your working folder.
The location for the files on your server is the application root folder you created in Create a root folder for your application. If IIS is running on your computer and you created an application folder in the wwwroot folder, then the remote location for the files is actually on your computer.
In the Advanced tab of the Site Definition dialog box, select Remote Info from the Category list.
The Remote Info screen appears.
In the Access pop-up menu, select how you want to move your files to and from the server: across a local network (the Local/Network option) or using FTP.
If the server is running on your computer, select Local/Network.
If the folder is on your hard disk, then that folder is considered to be the remote folder. The following example shows a possible Remote Folder path if you choose Local/Network access and your application root folder is on your Windows hard disk:
C:\Inetpub\wwwroot\MyWebApp
For more information on the FTP options, make sure FTP is selected as the access method and then click the Help button.
Leave the Site Definition dialog box open. Next, you define a folder for processing dynamic pages at design time.
After specifying your testing or production server, specify a server where Dreamweaver can process dynamic pages at design time. Dreamweaver uses this server to enable advanced ASP features such as displaying dynamic content in Design view or connecting to databases while you work on your ASP application. This server is normally the same server you specified as your testing or production server (see Specify your testing or production server).
In the advanced Site Definition dialog box, click Testing Server in the Category list.
The Testing Server screen appears. The testing server can be on your local computer or on a remote server. It can be a testing server, a development server, a staging server, or a production server, so long as it can process ASP pages. In most cases, you can use the same settings as the Remote Info category because they point to a server capable of processing ASP pages.
In the Access pop-up menu, select the same method you specified for accessing your remote folder (Local/Network or FTP).
Dreamweaver enters the settings you specified in the Remote Info category. Leave the settings unchanged.
In the URL Prefix text box, enter the URL you would enter in a web browser to request a page in your web application.
To display live data in your pages while you work, Dreamweaver creates a temporary file, copies it to the designated folder on the server, and attempts to request it using the URL prefix.
Dreamweaver makes a best guess at the URL prefix, based on the information you provided in the Site Definition dialog box. However, the suggested URL prefix may be incorrect. Correct the URL or enter a new URL prefix if the suggestion in Dreamweaver is incorrect. For more information, see About the URL prefix for the testing server in Dreamweaver CS4 Help.
For example, if the folder specified in the Remote Folder text box is C:\Inetpub\wwwroot\MyWebApp, then the URL prefix should be:
http://localhost/MyWebApp/
The URL prefix should always specify a folder, rather than a particular page on the site. Also, be sure to use the same capitalization you used when you created the folder.
You can start developing your own ASP web applications in Dreamweaver. The following section describes how to set up the sample ASP files included with this article.
If you like, you can copy the sample files included with this article to the working folder on your hard disk. Download and unzip the samples file included with this article.
Paste the folders and files in the MyWebApp folder into the application root folder you specified when defining the Dreamweaver site. Example:
/MyWebApp/ data/ index.asp insert.asp
Dreamweaver copies all the files to the server folder you defined in Specify your testing or production server.
You must upload the files even if the server is running on your local computer. If you don't upload the files, features such as Live Data view and Preview in Browser may not work properly with dynamic pages. For example, image links might be broken in Live Data view because the image files haven't been copied to the server folder yet.
The Dreamweaver site is now defined. The next step is to connect to the sample database included in the sample files.