Java Mailing List Archive

http://www.apache-httpd.com/

Home » modperl.perl »

Current working directory always "/"

william

2008-05-21

Replies: Find Java Web Hosting

Author LoginPost Reply
Hello,
It took me hours just to notice that my current working directory of
mod_perl2 always appear as "/"

Alias /modperl/ /var/www/modperl/
<Location /modperl/>
SetHandler perl-script
   PerlResponseHandler ModPerl::Registry
   PerlOptions +ParseHeaders
   Options +ExecCGI
   Order allow,deny
   Allow from all
</Location>


But either I place my script at /var/www/modperl/test.pl OR
/var/www/modperl/directory/test.pl
use CGI qw(:standard);
print header;

use Cwd;
print getcwd();


These always print out "/". I have some modules living in my working
directory how can I have the directory working as like no using the
mod_perl2 before ? Thanks
©2008 apache-httpd.com - Jax Systems, LLC, U.S.A.