[Xitami] Perl in a MSDOS box

Paul Reid xitami@lists.xitami.org
Fri, 01 Feb 2002 14:23:48 -0500


> After installing xitami server and activeperl I can run scripts ok but I
can't use perl in a dos box to check syntax (perl -c scriptname). I get
a "This Program cannot be run in DOS mode" message.

Also- since you have a web server and Perl on the Win98 machine, you could
stash your Perl script in the cgi-bin folder, open a browser, open
"http://localhost/cgi-bin/doodah.pl", and check functionality. That isn't much
use if you've made a big syntax error though. 

Use this on top of your scripts. If you make a not too big syntax error, this
will try to tell you about it. 

 BEGIN {
 use Env qw(REMOTE_ADDR HTTP_ACCEPT);
 use CGI qw(:standard);
 use CGI::Carp qw(fatalsToBrowser set_message);
 set_message("ooops!");
 };


 -PRR