Home > Archive > PERL Programming > March 2004 > Newbie Help
You are viewing an archived Text-only version of the thread.
To view this thread in it's original format and/or if you want to reply to
this thread please [click here]
|
|
| Alan Powell 2004-03-26, 11:16 pm |
| Hi all
Could someone offer me some advice please?
I have built an apache 2.0.48 server with MySQL 3.23.49 and PHP4.3.4 on a
Win2k server that has ActivePerl 5.8.3.809 loaded. All appears to be
installed correctly, perl runs scripts fine from the command prompt and my
webserving and php runs well. No IIS by the way.
Here is where I need to check some info: -
I have installed the simple Perl library from http://cgi-lib.berkeley.edu/
to my server; it is named cgi-lib.pl - do I need this generally speaking?
Now for my first foray into perl integration I have loaded the file
http://cgi-lib.berkeley.edu/ex/simple-form.html together with the script
http://cgi-lib.berkeley.edu/ex/simple-form.cgi.txt which I have renamed
simple-form.pl. All these files have been installed to my htdocs Apache
server directory to check that there are no path / settings issues (which I
am confident there aren't).
However, when the script tries to activate from the html, I get a download
box launch. I cannot see why at the moment. Can you help me please?
Thanks in advance
Alan
| |
| Gunnar Hjalmarsson 2004-03-26, 11:16 pm |
| Alan Powell wrote:
> I have installed the simple Perl library from
> http://cgi-lib.berkeley.edu/ to my server; it is named cgi-lib.pl
> - do I need this generally speaking?
No. cgi-lib.pl is a Perl 4 library. CGI.pm is a standard module in
Perl 5 that includes everything (and - unfortunately - much, much
more) of what cgi-lib.pl did.
> Now for my first foray into perl integration I have loaded the file
> http://cgi-lib.berkeley.edu/ex/simple-form.html together with the
> script http://cgi-lib.berkeley.edu/ex/simple-form.cgi.txt which I
> have renamed simple-form.pl. All these files have been installed
> to my htdocs apache server directory to check that there are no
> path / settings issues (which I am confident there aren't).
>
> However, when the script tries to activate from the html, I get a
> download box launch.
Note that this is a server configuration issue, not a Perl problem.
I would suggest that you drop that script, write a simple "Hello
world" script, and try to run that as a CGI script:
#!perl
print "Content-type: text/html\n\n";
print "Hello world!\n";
--
Gunnar Hjalmarsson
Email: http://www.gunnar.cc/cgi-bin/contact.pl
| |
| Alan Powell 2004-03-26, 11:16 pm |
| Gunnar
Thanks for that. I shall post to apache.configuration if I need to on this
in future. I have tried your simple Hello World script idea but still get a
download then the script in my editor.
Thanks again
Alan
"Gunnar Hjalmarsson" <noreply@gunnar.cc> wrote in message
news:c3v508$2c377p$1@ID-184292.news.uni-berlin.de...
> Alan Powell wrote:
>
> No. cgi-lib.pl is a Perl 4 library. CGI.pm is a standard module in
> Perl 5 that includes everything (and - unfortunately - much, much
> more) of what cgi-lib.pl did.
>
>
> Note that this is a server configuration issue, not a Perl problem.
>
> I would suggest that you drop that script, write a simple "Hello
> world" script, and try to run that as a CGI script:
>
> #!perl
> print "Content-type: text/html\n\n";
> print "Hello world!\n";
>
> --
> Gunnar Hjalmarsson
> Email: http://www.gunnar.cc/cgi-bin/contact.pl
>
|
|
|
|
|