|
|
sybperl-l Archive
Up Prev Next
From: "Pantera, Joseph F dot " <JPANTERA at gdclaw dot com>
Subject: Sybperl in CGI...
Date: Sep 20 2000 4:44PM
Sybperl Discussion Group:
Is there anyone out there who can help me with a quick tourn-around
in order to get some Sybperl scripts I've written displayed on an Apache
Server as a Perl / CGI? Sorry to clutter the message board (you can tell me
to go elsewhere if you give me a recommended place to go) with an issue like
this. I have not configured my Apache Server to run CGI scripts before. I
have some Sybperl scripts that I modified to add basic HTML directives to
the output. They work fine if I run the scripts as a perl executable on my
Apache Server / UNIX box, write to a file (say, sybperl_out.html in my
ServerRoot) and then display out of my brower at
http:///sybperl_out.html . It is not an issue with Sybperl,
since I cannot even get the canned "printenv" (print environment variables)
to run that automatically gets shipped in cgi-bin (yes, I made it
executable):
#!/bin/perl
##
## printenv -- demo CGI program which just prints its environment
##
print "Content-type: text/plain\n\n";
foreach $var (sort(keys(%ENV))) {
$val = $ENV{$var};
$val =~ s|\n|\\n|g;
$val =~ s|"|\\"|g;
print "${var}=\"${val}\"\n";
}
I have modified the Apache httpd.conf file with a ScriptAlias to point to
the location of the scripts, but nothing is displaying (in output) if I add
a directive in my HTML with a call like:
We're now going to execute /opt/apache/cgi-bin/printenv:
<< >>
But the ouptput looks like this:
We're now going to execute /opt/apache/cgi-bin/printenv: << >>
It is probably something missing from my httpd.conf, but I've been
scrambling around several different resources and nothing seems to work.
Needing to display this in browser format, since current scripts only
running on HP-UX, and my Windows users who need to run them are shuddering
at the prospects of telneting into a UNIX box to run them.
- Joe Pantera
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
Joseph F. Pantera Unix & Network Systems Administrator
Gibson Dunn & Crutcher LLP
mail: jpantera@gdclaw.com
pager: (213) 991-3688
phone: (213) 229-7673
-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-
==============================================================================
This message may contain confidential and privileged information. If it has been sent to you in error, please reply to advise the sender of the error and then immediately delete this message.
==============================================================================
|