- 论坛徽章:
- 0
|
原帖由 web_jockey 于 2006-8-1 15:24 发表
我在linux下也装了一遍,还是不行,但我朋友就行.httpd.conf 里的LoadModule perl_module modules/mod_perl.so也加了。http2.2.X perl5.X mod_perl2.02
你完全弄錯方向了。
你要的是學學 apache cgi 的配置執行方式,而不是使用那各 mod_perl module。
mod_perl 是讓 html page 內可以嵌入 perl code,這個與你預期的 perl cgi 程式執行完全是沒有關係的部份。
suse linux 的 /etc/apache2/default-server.conf 可以找到:
- ScriptAlias /cgi-bin/ "/srv/www/cgi-bin/"
- # "/srv/www/cgi-bin" should be changed to whatever your ScriptAliased
- # CGI directory exists, if you have that configured.
- #
- <Directory "/srv/www/cgi-bin">
- AllowOverride None
- Options +ExecCGI -Includes
- Order allow,deny
- Allow from all
- </Directory>
复制代码
所以把 cgi 程式放到 /srv/www/cgi-bin/ 目錄內,後續網頁使用 http://hostname/cgi-bin/xxx 即可瀏覽執行。
或者是你應該先看看 apache manual :
http://httpd.apache.org/docs/2.2/howto/cgi.html
== |
|