HowTo: Set Up Dynamic Content with WebDAV on Internet Information Server

CONTENTS

Stage 1: Create and configure the WebDAV virtual directory
Stage 2: Create the second virtual directory
Stage 3: Configuring the GoLive site


Stage 3: Configuring the GoLive site

We've set up both the virtual directories we need to work with WebDAV and dynamic content. All that's left is to set up the GoLive site to use the directories we've created.

Open or create the site you want to make dynamic.

Open the site settings from the site window toolbar or using the Site > Settings menu.

Select the Dynamic Content section in the site settings and click the Dynamic Site Wizard button.

Fire Up the Dynamic Site Wizard

Now check the checkbox for the server-side scripting language you want to support. It will probably be ASP as we are on an IIS server, but hey, maybe you have another scripting engine installed. We'll go with ASP here.

Select the Server-Side Scripting Language

In the Connecting to Server dialogue click the WebDAV radio button, then open the dropdown and choose Edit Server.

Choose WebDAV Connection

You must now set up the details of the WebDAV server in the Edit Servers dialogue. The nickname can be anything you wish. The server is the name or IP address of the server machine. Its localhost here simply because I set it up on a local machine to prepare the HowTo. Normally you would not use WebDAV if the web server and GoLive were on the same machine as it would be much easier just to serve it directly.

The directory is the WebDAV virtual directory we set up in Stage 1. If you followed the steps in Stage 1, put the forward slash in before the directory name.

Set up the WebDAV Server Details

Once you've finished the details click OK and you will return to the Dynamic Content Wizard. The newly defined server should be sitting there expectantly in the WebDAV Server Name box.

Click Next and you will be asked for the Web Site address. This is the server name followed by the second virtual directory we set up in Stage 2.

Enter the Site Root URL

After you click Next, a number of things could happen. First off, you might see the following warning.

Warning: GoLive could not find ...

Don't panic. Cancel the wizard ... and start the wizard again. I've lost count of the number of times the wizard has failed first time but not the second, without changing anything in between, when setting up WebDAV. I've given up asking why it happens. If it fails again, cancel out and then go and double-check that the virtual directories you set up are correctly configured, that you didn't leave an entry for ASP, PHP or JSP in the application configuration of the WebDAV virtual directory and that the server and directory names you used in GoLive match what you set up in IIS. If you still get the same thing, cancel out of the wizard and refresh the site files side of the site window. You should have a directory called ___test in the local site. Click on the WebDAV connect button in the site toolbar and connect to the WebDAV server (this should connect you to the WebDAV directory you set up in the Edit Servers dialogue earlier. You know you are successfully connected when the WebDAV tab shows the URL for the WebDAV directory. In our case that's http://localhost/dav_dynamic. Now drag the ___test folder across to the WebDAV side of the site window. Once its transferred, try running the dynamic site wizard again.

Once you get past this point, you may see a Server Transaction message and at a certain point you will be presented with the WebDAV synchronization dialogue.

Synchronize the Site

Click the Synchronize button in the dialogue to continue, and the Security dialogue will come up. You enter the IP address or subnet you want to allow access for here. GoLive will fill the allowed IP address with the machine you are setting up dynamic content from. Its not usually necessary to change this if you are working on your own. If you need to set subnet access, chances are you will want to talk to your network administrator or IS Helpdesk first.

Security Setup

GoLive then installs the configuration files in the local site.

Installing Configuration Files

You will then get a synchronize dialogue to upload the GoLive configuration files from the local site to the WebDAV server. Click the Synchronize button again.

Synchronize Site

GoLive will then check whether there are any datasource already set up for the site. If you are creating you own dynamic site, there won't be. After the check completes, hit the Finish button and you've done it. You've set up a dynamic content site on IIS using WebDAV for the file transfer process. You will return to the Dynamic Content site settings, but now instead of just a wizard button it will show the details of the dynamic site. To test your server for any issues which might affect dynamic content development, select the server-side language and hit the test button.



Mission accomplished. The good stuff, actually developing your dynamic site, starts now.