Here’s what you want to do:

  • You want your Windows 2000 web server to always execute files with a *.cgi extension.
  • You want your Windows 2000 web server to parse the ASP code that you’ve embedded in files that end in *.htm, *.shtml, *.css.
  • You want your Windows 2000 web server to know that it needs to parse these file types for all the domains on the machine and you don’t want to modify the settings for each domain.


Here’s how you do it:

  1. Open IIS. (Click “Start”, “Administrative Tools”, “Internet Information Services”.)
  2. Right-click the web server and select “Properties”. (It should be the first computer in the left-hand pane. It most likely has an asterisk * next to it.)
  3. On the “Internet Information Services” tab (the first one you see), click the “Edit …” button next to “WWW Service” in the drop-down combo box titled “Master Properties”.
  4. Select the “Home Directory” tab.
  5. Click the “Configuration …” button located near the lower right-hand side of the tab.
  6. Check to make sure that the extension you are modifying is not already in the list!
  7. Click the “Add” button.
  8. Use the “Browse …” button to find the path to the executable you want to handle parsing files with the extension you are about to modify. (ex. “C:\WINNT\System38\inetsrv\asp.dll” if you want to parse ASP code in the file; “C:\Perl\Perl.exe %s” if you want to parse the file as if it had a *.pl extension. NOTE: Your paths will be different from mine.)
  9. Add the extension you want to modify. (ex. “.css“, “.cgi“)
  10. Change the verbs to “GET, POST, HEAD”. (I don’t know why. Just do it. It works.)
  11. Click “OK” until you get all the way back to the main screen.
  12. You will – most likely – have to restart the IIS service on the machine.

There is one comment on this post

  1. Hi, I know this is not to do with the 2000, but it has to do with Advanced Server 2003 IIS. I am able to run an executable via the address bar, but cannot add an extension i.e. ins.exe/search. The IIS is recognosing the exe but cuts the rest of the extension off.

    Do you know why? And how i can work around or through this problem!

    Thanks

Add to the discussion:

I'll never share your email address and it won't be published.

What Is This?

davidgagne.net is the personal weblog of me, David Vincent Gagne. I've been publishing here since 1999, which makes this one of the oldest continuously-updated websites on the Internet.

bartender.live

A few years ago I was trying to determine what cocktails I could make with the alcohol I had at home. I searched the App Store but couldn't find an app that would let me do that, so I built one.

Hemingway

You can read dozens of essays and articles and find hundreds of links to other sites with stories and information about Ernest Hemingway in The Hemingway Collection.