Re: [opensuse] perl cgi on opensuse10.2



Dear my friends...

I found that my perl cgi script only run if they're placed into /srv/www/cgi-bin.

Could I have some other locations for keeping and running my perl cgi script by my apache2?

ScriptAlias /cginya/ /srv/www/htdocs/klien/beol/cgi-bin
<Directory /srv/www/htdocs/klien/beol/cgi-bin>
Options ExecCGI
</Directory>

This does not work as I expect.

Please tell me.

Thank you very much in advance.

On Fri, 21 Sep 2007 21:01:36 +0700
Patrik Hasibuan <patrikh@xxxxxxxxxxxxxxxxxxxxx> wrote:

Dear my friends...

I use opensuse10.2.

I am developing a website using perl for it cgi. This is the firsttime for me to use perl for website application.
I've installed perl::CGI and create a very simple script as the very first step:
"
#!/usr/bin/perl
print "Content-type: text/html";
print "<html>";
print "<head>";
print "<title>";
print "Try if the webserver understand my perl CGI";
print "</title>";
print "</head>";
print "<body>";
print "tes dulu";
print "</body>";
print "</html>";
".
But my apache2 does not understand my perlscript.

I put the script (index.cgi) under /srv/www/htdocs/klien/boel/cgi-bin so the url of my first perl cgi script (index.cgi) is: http://127.0.0.1/klien/beol/cgi-bin/index.cgi .

I tried to find the solution by looking up on my perl book. I found about ScriptAlias. So I add this lines into the "httpd.conf":
ScriptAlias /cgi-bin/ /srv/www/htdocs/klien/beol/cgi-bin
<Directory /srv/www/htdocs/klien/beol/cgi-bin>
Options ExecCGI
</Directory>

If I restart the apache2 I get this error message:
"
suseonthelap:/etc/apache2 # rcapache2 restart
[Fri Sep 21 20:56:08 2007] [warn] The ScriptAlias directive in /etc/apache2/httpd.conf at line 215 will probably never match because it overlaps an earlier ScriptAlias.
Syntax OK
Shutting down httpd2 (waiting for all children to terminate) done
Starting httpd2 (prefork) [Fri Sep 21 20:56:11 2007] [warn] The ScriptAlias directive in /etc/apache2/httpd.conf at line 215 will probably never match because it overlaps an earlier ScriptAlias.
done
suseonthelap:/etc/apache2
"

Please tell me what I should do to make my apache2 understand the perl cgi script.

Thank you very much in advance.
--
Patrik Hasibuan <patrikh@xxxxxxxxxxxxxxxxxxxxx>
Junior Programmer
--
To unsubscribe, e-mail: opensuse+unsubscribe@xxxxxxxxxxxx
For additional commands, e-mail: opensuse+help@xxxxxxxxxxxx





--
Patrik Hasibuan <patrikh@xxxxxxxxxxxxxxxxxxxxx>
Junior Programmer
--
To unsubscribe, e-mail: opensuse+unsubscribe@xxxxxxxxxxxx
For additional commands, e-mail: opensuse+help@xxxxxxxxxxxx



Relevant Pages

  • Catching output of system()
    ... I've written a perl cgi script but it's too slow so I need ... a search engine on our local filesystem and processes the ... search results to the program through the operating system ...
    (comp.lang.cpp)
  • Perl and JavaScript Issue
    ... I have written a Perl CGI script to dynamically generate HTML and Javascript code for a web page. ...
    (perl.beginners)
  • Re: Newbie: Perl cgi and apache
    ... somebody> I'm running apache 2.x under Linux. ... somebody> show me an example of a simple perl cgi script that displays ...
    (comp.lang.perl)
  • Re: Script debugging
    ... Quoth Adam Smith: ... I am running a perl cgi script and am getting an error message to my http error log files ...
    (comp.lang.perl.misc)
  • Re: Why Tcl; the universal scripting language
    ... threaded Tcl and cannot currently run with Apache2. ... repository. ... I have only seen poor Perl code so far. ... I have my opinion on perl - a rather bad one. ...
    (comp.lang.tcl)