in reply to Physical location of a requested URI

Here's a CPAN module that will give you the current directory name. Or if you prefered not to install a module you can capture the output of the 'pwd' command with backticks:

my $dirpath = `pwd`;

If you are on Windows it appears that CPAN module is the better choice as it seems to have support for Windows. I don't know of a windows command that gets the current directory (though I don't use windows so there probably is and I just don't know about it.)

Hope that helps
Chris

Lobster Aliens Are attacking the world!

Replies are listed 'Best First'.
Re: Re: Physical location of a requested URI
by jsprat (Curate) on Mar 06, 2003 at 15:34 UTC
    Hi,

    pwd won't necessarily give the answer you're looking for on a web server. If it does, it's likely to be a coincidence.

    Oh and instead of using pwd or `pwd`, you probably are looking for use Cwd;. It's part of the standard distribution and platform agnostic (but still won't give a URI's path on the filesystem).