Peter,

Theoretically you are right, but somehow on WIN98 that doesn't seem
to be true all the time, so it is more safe to call perl with the
script as a parameter, that always works...

I think the perl installation in itself is ok, Sambar seems to find
the perl executable.

I forgot to mention that if you want to use perl on a webserver,
all the output of your script has to be HTML, otherwise your browser
will see it as pure text and will try to display everything on one
single line... (wordwrapped)

The remark from your friend as perl means trouble on Windows...
I'm a perl programmer (amongst other languages) for several years
now and have always worked under Windows, never had a problem
(that I didn't create myself... ;-) )

My 4 cents,

Frank
 

Under Windows you need the perl executable to execute the script,
so just typing "x.pl > errors.txt" on the dos prompt won't work,
try this in a DOS-box: "C:/Perl/bin/perl.exe x.pl" assuming
perl is in C:/Perl/bin/perl.
If this does not work, go to C:/Perl/bin en type "perl" en hit
<return>, the c:\> prompt should disappear, hit <ctrl>+c to exit.

Needless to say that you don't type the ", < and >...

A quick note:
It is better not to use the perl version from the Sambar installation,
instead install the latest ActiveState, especially if you are planning
to run some complicated scripts.


Frank.


-----Original Message-----
From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] On Behalf Of
Peter
Sent: jeudi 24 juin 2004 16:15
To: sambar List Member
Subject: [sambar] still trying...

For my 2 cents unistall sambar and perl and start again. Install sambar to
C:\sambar and perl to C:\perl I also seem to remember that some win builds
need a bat file in the C:\directory or something to make it work
correctly. Then run the envir.pl to make sure its all working. Once it is
move most of those pl's out of the cgi-bin for security. Better yet read
the sambar docs on security and running cgi's for a better idea of what
you are up against.

-----Original Message-----
From: [EMAIL PROTECTED] (cherie)
To: "sambar List Member"  <[EMAIL PROTECTED]>
Date: 24 Jun 2004 02:40:24 +0200
Subject: [sambar] still trying...

> > Have you tested your script in a dos box? 
> > cd\path to script\ 
> > script name > errors.txt 
> > 
> > Peter 
> > Peter: Thank you some more.  My script is in
> C:\temp\sambar60-1\cgi-bin\  It is called x.pl.  Here it
> is:[quote:d9555c8967]#!C:/Perl/bin/perl.exe -wT
> print "backslash n won't work for newline or backslash t for tab!
> \n";
> print "Hello,World!\tHelloWorld!\nHello,World!";[/quote:d9555c8967]
> 
> In IE, http://localhost/cgi-bin/x.pl prints out one line only.  The
> 'hash line' points to my installation in C:\Perl\ yesterday.
> 
> If I open a DOS window on my Windows98 machine, and cd to
> C:\temp\sambar60-1\cgi-bin\  I can then do a DOS dir command and I
> see that x.pl is present.
> I then type x.pl>errors.txt   and the DOS line says 
> Bad command or file name
> 
> if I type C:\temp\sambar60-1\cgi-bin\x.pl > errors.txt   the same
> thing happens.  Somebody told me to try ./x.pl or
> /x.pl>errors.txt  but the same thing comes back:  Bad command or
> file name.  This script works from the browser, albeit without \n
> etc.  I'm in way over my head, I think.
> My friend says she had a lot of problems like this in windows and I
> should find a UNIX server to use.  Or Linux.
> 
> -------------------------------------------------------
> To unsubscribe please go to http://www.sambar.ch/list/
> 
> 

-------------------------------------------------------
To unsubscribe please go to http://www.sambar.ch/list/



-------------------------------------------------------
To unsubscribe please go to http://www.sambar.ch/list/



-------------------------------------------------------
To unsubscribe please go to http://www.sambar.ch/list/



Reply via email to