Personal Web Server and CGI

I know it is possible to use CGI with Microsoft's Personal Web Server but I guess I'm not setting it up correctly.  I know about the 2 registry entries to register the .pl and .cgi extensions to run perl but that still isn't working.  Please Help!!!!  Thanks in advance.
Who is Participating?

Improve company productivity with a Business Account.Sign Up

gravityConnect With a Mentor Commented:
To set up php, have a registry entry of

php = "C:\PHP3\php.exe"

or wherever you have it set up. You need to copy the php3.ini-dist file to your windows directory and call it php3.ini as stated in the readme file.

When I set up Perl to do the same thing (version 5, btw) I only needed the reference to the perl exe itself ie no %s %s :

pl = "C:\Perl5\perl.exe"

By the way, you are using invcerted commas ?

Hi, do you have the execute permissions setup correctly?

I run php on a personal webserver in WinNT and I have no problems what so ever......php is pretty much like perl itself.

Please give me more info in order to be able to ehlp you!

heydougAuthor Commented:
I have the execute and read permissions set.  I actually got a Perl script to run but the ones that follow are giving me difficulty.  I figured out that I had to put the location of the Perl interpreter in the Unix format:  #!c:/progra~1/perl/bin and it worked okay but I'm still having problems.  Help!  Thanks!
Free Tool: Subnet Calculator

The subnet calculator helps you design networks by taking an IP address and network mask and returning information such as network, broadcast address, and host range.

One of a set of tools we're offering as a way of saying thank you for being a part of the community.

Do you need to use perl for your cgi's or are you willing to take one step further and use PHP?

I've been developing cgi's for many years, and since I installed PHP (which is free, runs in unix, linux and winnt), cgi development has become much easier.

I really don't know what the problem is, but If you change to php ill help you out in any way I can to get you set up.


What kind of Win you use - Win95 or WinNT,
What kind of perl you have - Activestate, hip or other?
heydougAuthor Commented:
Yes, I need to use Perl for my CGI, but I'm using Win95 and ActiveState Perl for Win95 version 5.03.  I cannot use the PHP unless it runs on Win95.  Do they have a port for Win95?
Its the same will run on both.

What you might have to do under 95 is to run php as a cgi, not as a web-interpreted script.

     http://localhost/webpage.php3                                       //Web Interpreted.
     http://localhost/cgi-bin/php.exe?path/to/webpage.php3    //Cgi version

I have ran both under NT, but can't remember doing so under 95.  Either way, your script will run just fine :)

Most likely Your problem is still in registry, show me your current registry setting and hopefully I can tell you where you are wrong.

BTW, what extension do you want to use? .pl or .cgi?  And do you want to use the exe version or the dll version of perl?
See FAQ section
My program runs fine from the command line, but bombs out when run as a CGI script.
heydougAuthor Commented:
Regestry entries:
  .cgi  =  c:\progra~1\perl\bin\perl.exe %s %s
  .pl   =  c:\progra~1\perl\bin\perl.exe %s %s
  .idc  =  C:\WebShare\Scripts\httpodbc.dll

I've tried using .pl and .cgi.  My script reads an ini type file to get which extension to use becuase some webservers use .cgi and others use .pl. So I programmed it to use both.  

I'm trying to use the .exe version of Perl.  I don't know how to set up the dll version.  

Oh, what if instead of using the php like:     http://localhost/cgi-bin/php.exe?path/to/webpage.php3
I do something like with perl.exe:

Thanks so much for all your help.  It is getting me closer and closer each time!
heydougAuthor Commented:
Thanks for the info on the matter.  I was unable to get it to work though.  I thought you would want the points for this though.
I must admit that I no longer use the microsoft server. I now use Xitami, which is a lot easier and versatile to set up...

try it @

heydougAuthor Commented:
Actually this wasn't for me.  A customer of my company wants to run a program we did in CGI and he uses FrontPage (because he is to lazy to learn HTML) and it has all those stupid Microsoft Extensions and they aren't supported by the server (OmniPro Httpd) that we were using.  Bummer.

Thanks anyway!!!!!
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

All Courses

From novice to tech pro — start learning today.