Sorry,
got it working with your advice:
opendir(DIR, "G:/FTP/Ski") or die print "Error $!"; worked in the end...
Damn these slashes :-D
Thanks for the help
--
View this message in context:
http://old.nabble.com/How-to-get-a-file-listing-tp27644565p27668922.html
Sent from the mod_perl - Genera
No,
that doesn't work either. I used opendir (DIR, "G:\FTP\Ski") ...
I've tried the slashes in all directions, and with and without preceding and
slashes in the end.
e.g. \Ski, \Ski\, /ski, /ski/
How do I get perl to understand the context? is there some function that
points to the root? (even
Hi there
Here is my code. I get the IMG displayed but also the perl error: No such
file or directory.
"
#!E:\ea12\apps\tech_st\10.1.2\perl\5.6.1\bin\MSWin32-x86\perl.exe
print "Content-type: text/html \n\n";
print "Test:";
print " /Ski/temp.jpg ";
opendir(DIR, "/Ski") or die print "Error $!";
Hi guys
Running apache on winxp.
The bizarre thing is in my browser I can put:
myserver.com/mydir2/test.gif and that works
myserver.com/cgi-bin/mydir/test.gif gives internal server error. but I know
the opendir command can at least read mydir. Still, how should I 'enable'
mydir2?
another issue
Wow, thanks. It's working. I have a problem with the dir structure:
Perls seems to search for mydir in \cgi-bin\ and not where I defined mydir
in the apache conf file.
So my structure is like this:
\cgi-bin\myprog.cgi < my program
\cgi-bin\mydir1\ <- this one can be seen by my program
Sorry, I completely forgot to say.
This is for MOD_PERL on apache. So I want the webserver to show an unknown
amount of pictures.
--
View this message in context:
http://old.nabble.com/How-to-get-a-file-listing-tp27644565p27644823.html
Sent from the mod_perl - General mailing list archive at N
Hi guys
I wanted to do a simple script to show all pictures in a specific folder.
But I don't see any functions to read all files in a folder.
The logic needs to go something like this:
- Open directory to read file list
- If file like *.gif then print filename
Any tips?
--
View this message