[Date Prev][Date Next][Thread Prev][Thread Next] [Search] [Date Index] [Thread Index]

[MacPerl-WebCGI] Re: [MacPerl] MacPerl and Webatar



[Because this is a CGI question, I have cross posted to MacPerl-WebCGI]

>I've just installed macperl and gave the added the action PERL  --> 
>path to MacPerl
>and the suffix map .pl --> action PERL
>
>can i now get any old script written in perl, call it something.pl 
>and execute-it from the browser?

No.  See below.

Normally, CGIs with WebSTAR have the .cgi filename extension.  I am 
not currently useing WebSTAR, but what you have done may allow you to 
the the .pl filename extenstion as well IF YOU SAVE AS CGI SCRIPT 
(below).

>do i need to do something else, like change the shebang line to 
>reflect where perl is?

The shebang line is much less important for MacPerl than for Unix 
Perl.  It is unnecessary and frequently ignored.

For a MacPerl script to function as a CGI, you *must* save it as a 
CGI Script.  This is an option when you select Save As... from the 
file menu of the MacPerl application.  If you are trying to run a 
Perl CGI from somewhere else, you need to open in in MacPerl and to a 
Save As.. to CGI Script.  Plain Text (the default) will not work. 
Droplet will not work.  Standalone Application will not work.  Only 
CGI script will work.

-David Steffen-
David Steffen, Ph.D.
President, Biomedical Computing, Inc. <http://www.biomedcomp.com/>
Phone: (713) 610-9770 FAX: (713) 610-9769 E-mail: steffen@biomedcomp.com

==== Want to unsubscribe from this list?
==== Send mail with body "unsubscribe" to macperl-webcgi-request@macperl.org