Re[3]: [Xitami] Xitami, Perl, and Win2000

Paul Reid xitami@lists.xitami.org
Fri, 23 Aug 2002 12:12:34 -0400


>  one of the scripts I tested asked for the PATH_TRANSLATED to be
> set properly... I have no idea at the moment what that means,

Don't look for problems until they bite you. Xitami generally sets
PATH_TRANSLATED to a workable value before calling the script.

Install Xitami. Open http://localhost in a browser on the same
machine and see if you see "Welcome To Xitami". Open
http://localhost/admin, give the secret word you gave when you
installed Xitami, and look at the many options. Under Configuration,
CGI, be sure "CGI Enabled?" is checked. Save back to main Admin
screen. Under Configuration, MIME, add an entry saying that ".pl" is
"text/html". Save back to main Admin screen.

Install Perl.

Create a folder C:\Xitami\cgi-bin

Unpack your script there. Figure out which file is the main script,
probably with a "/pl" extension. Let us say it is yak.pl

Wait a second. ShoppingCart and MessageBoard scripts are maybe the
WORST things to start with. First we will just see if Perl works.

Use NotePad to create a file C:\Xitami\cgi-bin\hello.txt The
contents of that file should be:

#! /fee/foo/perl
print "Hello, world!";

Save it, close NotePad, rename the file to "hello.pl", ignoring
Windows whining about changing file extensions. (Uh, you really
should not have Windows "hiding known file extensions"; that is one
of Gates' dumbest ideas.)

Reboot Windows. There are ways to avoid this, but I think it is best
when the server isn't in 24/7 heavy duty. Rebooting picks up some
changes to PATH that Perl added. You can add them manually for one
boot, but Perl sets it up to be set on every boot, and you may as
well find out if it worked.

Open a browser to http://localhost/cgi-bin/hello.pl If all is well,
you should see "Hello, world!" If not, write back with exactly what
happens.

With the simple Hello Perl program working, try
http://localhost/cgi-bin/yak.pl Maybe it works, maybe it starts in a
SetUp mode, and maybe it chokes. Write back if it fails, and say
exactly what happens and which script you are using with a link to a
website where you got it.

 -PRR