Re: CGI displays contents of script
- From: "J. Gleixner" <glex_no-spam@xxxxxxxxxxxxxxxxxxxxx>
- Date: Tue, 31 Jul 2007 14:00:46 -0500
jackson_samson@xxxxxxxxxxx wrote:
On Jul 31, 2:43 pm, Paul Lalli <mri...@xxxxxxxxx> wrote:On Jul 31, 2:38 pm, jackson_sam...@xxxxxxxxxxx wrote:
I have installed perl 5.8.8 which already has the CGI included in it.Because your web server is configured to display .cgi scripts rather
I created a small test script that uses the CGI.pm. When I run the
following in my browser, it shows me the entire script and does not
execute the script. Does anyone know why this happens?
Here is my output from the web browser:
#!/usr/bin/perl use CGI; print "Content-type: text/plain\n\n"; print
"TEST";
than execute them. This has nothing to do with Perl and everything to
do with web server configuration. You will get better assistance from
a group that talks about web server configurations.
Paul Lalli
That makes sense. Thanks for your answer.
Also, once you modify your Web server, the shebang line should be on a line by itself.
#!/usr/bin/perl
use CGI; print "Content-type: text/plain\n\n"; print "TEST";
or.. actually using the CGI module...
#!/usr/bin/perl
use CGI qw( :standard );
print header( 'text/plain' ), 'TEST';
.
- Follow-Ups:
- Re: CGI displays contents of script
- From: Paul Lalli
- Re: CGI displays contents of script
- References:
- CGI displays contents of script
- From: jackson_samson
- Re: CGI displays contents of script
- From: Paul Lalli
- Re: CGI displays contents of script
- From: jackson_samson
- CGI displays contents of script
- Prev by Date: Re: CGI displays contents of script
- Next by Date: NULL value question
- Previous by thread: Re: CGI displays contents of script
- Next by thread: Re: CGI displays contents of script
- Index(es):
Relevant Pages
|
|