khangol has asked for the wisdom of the Perl Monks concerning the following question:
If I open a web browser on the hosting server and click the link, the script will work and display the contents of the folder, however, when I try it on any other server, it gives the error: No such file or directory. The script works on any server if run from the command line.#!/usr/bin/perl -w print "Content-type: text/html\n\n"; $dirname = "\\\\host01\\ISO"; opendir ( DIR, $dirname ) || print "error: $!<br>"; while( ($filename = readdir(DIR))){ print("$filename<br>"); } closedir(DIR);
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Hyperlinking to Perl script to access network shares.
by ahmad (Hermit) on Jul 21, 2010 at 15:37 UTC | |
|
Re: Hyperlinking to Perl script to access network shares.
by intel (Beadle) on Jul 21, 2010 at 22:22 UTC | |
|
Re: Hyperlinking to Perl script to access network shares.
by Sinistral (Monsignor) on Jul 22, 2010 at 18:17 UTC | |
by Anonymous Monk on Jul 26, 2010 at 15:17 UTC |