CGI/Perl Guide | Learning Center | Forums | Advertise | Login
Site Search: in

  Main Index MAIN
INDEX
Search Posts SEARCH
POSTS
Who's Online WHO'S
ONLINE
Log in LOG
IN

Home: Perl Programming Help: Intermediate:
running Perl cgi scripts in NT and IIS

 



spaz
Novice

Nov 2, 2000, 9:21 AM

Post #1 of 4 (326 views)
running Perl cgi scripts in NT and IIS Can't Post

I need to run some Perl scripts in NT and IIS. I have scripts I now run on UNIX. How do I need to code the first line of the .cgi script? I have now:

#!/usr/local/bin/Perl5

Which doesn't work on NT apparently. Do I need to map out the location to Perl.exe? Also, what is the syntax with the "#!". Any help is appreciated.


sleuth
Enthusiast / Moderator

Nov 2, 2000, 7:42 PM

Post #2 of 4 (326 views)
Re: running Perl cgi scripts in NT and IIS [In reply to] Can't Post

 
On NT systems the path to perl is usually not needed, but like ohers have pointed out, on apache for win32 sytems, you do. something like #!C:\Perl\Perl.exe.

But 80% of the time it's all configured via regestry keys & file associations. If you read this post
http://www.perlguru.com/forum/Forum11/HTML/000033.shtml

I think you will find what your looking for.

Sleuth


slavdaddy
Deleted

Nov 4, 2000, 3:02 PM

Post #3 of 4 (326 views)
Re: running Perl cgi scripts in NT and IIS [In reply to] Can't Post

If you still need to know how to run perl on IIS, then check this out. Under IIS, right-click on whatever website you are trying to run perl under, and go to the home directory tab. Then click on configure, and see if .pl or .cgi extensions are configured. If not, click on the add button. Under the executable field, type:

c:\perl\bin\perl.exe %s %s

where c:\perl\bin\perl.exe is the full path and file name of perl. Also, the capitilazation of %s %s matters, and so do the spaces. The top lin should be

#!c:\perl\bin\perl.exe

and you should eb set to go.
-Corey


dws
Deleted

Nov 4, 2000, 9:49 PM

Post #4 of 4 (326 views)
Re: running Perl cgi scripts in NT and IIS [In reply to] Can't Post

Under IIS (and PWS) the #! line is ignored for purposes of finding Perl, but is honored (by ActiveState Perl) for command-line switches.

#!/dev/null -w

Works just fine.

 
 


Search for (options) Powered by Gossamer Forum v.1.2.0

Web Applications & Managed Hosting Powered by Gossamer Threads
Visit our Mailing List Archives