in reply to Perl cgi script for directory listing and file downloading!! Problem: Unable to download the file

What is the URL for the files as you see them in the browser?

The URL needs to be a http:// URL, not a filename local to your server machine.

  • Comment on Re: Perl cgi script for directory listing and file downloading!! Problem: Unable to download the file
  • Download Code

Replies are listed 'Best First'.
Re^2: Perl cgi script for directory listing and file downloading!! Problem: Unable to download the file
by masood91 (Novice) on Nov 05, 2014 at 11:48 UTC
    I am running my script via WAMP server, with the script file located in /www folder. Where should I put my files, so that they can be downloaded.!! ??

      This is a browser configuration issue.

      I guess that, for example, /www/download might be a good place for your files.

      You need to learn about how your webserver maps URLs to files and appropriately configure the webserver. First get the URL download working without your script by going directly to the URL with your browser. Then you can generate the URLs from your script.

        ok, but what will be the path for opendir, will it be my $dir='/www/Documents' or will it be $dir='C:/wamp/www/Documents ...? What is the default directory if i dont give any path?