The Microsoft Personal Web Server (PWS) is a great application for allowing your computer to distribute documents on the HTTP protocol (port 80). There may be some security holes in the application so check for updates.

     Download the Microsoft PWS application and install the software. Create a folder on your hard-disk that will be the root for HTTP distributed documents. Set the PWS application's settings to reflect this folder as the root directory. You may prefer to have the application run when the Windows operating system starts.

     Configuring the PWS application is a simple task and is not the scope of this document. More advanced concepts such as installing CGI access to the PWS and changing the HTTP port will be explained.


Setting up PWS to run Perl

Prerequisites:
     The Microsoft Personal Web Server (PWS) must be installed on the system.

Install PERL:
  1. Download and install Perl for Windows 95/NT
  2. Make sure that the installation updated your path in your c:\autoexec.bat file to include x:\perl\bin
    (where x: is the drive letter you installed Perl).
The Setup:
     The above steps will install Perl 5 on your Windows 95/NT PC. The steps below will configure the Microsoft Personal Web Server to run Perl 5.
  1. Click on Start, Run, regedit.exe
  2. HKEY_LOCAL_MACHINE/System/CurrentControlSet/Services/W3Svc/Parameters/Script Map
  3. Right click within the right pane/frame (of Script Map) and select New->string value.
  4. Enter .pl
  5. Modify .pl and enter the full path to the perl.exe program along with "%s %s"

    Example: x:\perl\bin\perl.exe %s %s

  6. Create additional entries for ".cgi" and ".plx"
  7. Exit Regedit.
  8. If PWS is running, start and stop http services.

    See Configuring and Testing a PERL Script with IIS if you have any questions.
The steps below will set up a cgi-bin or cgi-local (your choice) folder for use with Perl scripts:
  1. Start Windows Explorer.
  2. Go to your root folder and create a new folder named cgi-bin.
  3. Within Explorer, right click on the cgi-bin folder and select properties.
  4. Go to the "Web Sharing" tab and select "Share this folder".
  5. Select the folder in the Aliases textbox and the press "Edit Properties".
  6. Check the boxes to allow Scripts and Executions to be run.
Troubleshooting:
     If you do the above and it does not work, then check the following:

Changing the HTTP port

     While the Microsoft Personal Web Server for Windows 95 is designed to run on the standard HyperText Transport Protocol (HTTP) port 80, it is sometimes more desirable to run the Web server on a non-standard port such as 8080. The following information describes the process of changing the default port.
  1. Determine the correct hexadecimal value to use. To do this, follow these steps:
  2. Stop the Microsoft Personal Web Server
  3. In the Registry Editor, do the following:
    1. Select the following registry key:
      HKEY_LOCAL_MACHINE\System\CurrentControlSet\control\ServiceProvider\ServiceTypes\W3Svc
    2. In the right pane, click TcpPort.
      This is the TCP/IP port that the Microsoft Personal Web Server listens to in Hexadecimal (Base 16).

      NOTE: Hexadecimal (Base 16) notation is comprised of the numbers 0 through 9 and the letters A through F. The counting sequence is 0, 1, 2, 3, .... 9, A, B, D, E, F, 10, ...., where 10 is actually the decimal value 16. Single-byte (8-bit) values are represented by the hexadecimal numbers 00 through FF; and two-byte (32-bit) values are represented by the hexadecimal numbers 0000 through FFFF. Often when working with hexadecimal, values are entered in a reverse-order, or low byte-high byte format. That is to say, if the true value in hexadecimal was 1122 you would enter the value in reverse-order as 2211. When working with the Microsoft Personal Web Server you will need to enter two-byte values in this fashion.

    3. Double-click "TcpPort" in the right pane.
    4. In the Edit Binary Value dialog box, enter the hexadecimal value you identified in step 3. Make sure to enter the value in reverse-order format if it is a 16-bit value, and then close the Registry Editor. For example, if you want to use port 8080, which is 1F90 in hexadecimal, type this value in the Edit Binary Value dialog box:

      1F90