Re: Using Files from mapped drives
- From: Jon.Macpherson@xxxxxxxxx
- Date: 13 Mar 2006 13:29:54 -0800
Sorry Paul, I was a bit stressed out, however I did find a fix, and I
would like the whole world to know what it is, hopefully no one else
will ever have to sweet like that over a dumb problem. The fix is to
use the UNC name of the shared resource. for example, I was trying to
use the r: drive for \\10.1.69.3\rdrive , but in order to access those
files, the following format is needed:
\\\\10.1.69.3\\rdrive\\http\\admin\\records.gamma
To anyone who has the smae problem I had, simply double up the slashes
( since perl thinks \ is trying to include a new line or such ).
So the code that works is as follows:
open (FILE, "\\\\10.1.69.3\\rdrive\\http\\admin\\records.gamma") || die
"cannot open due to $!";
@lines = <FILE>;
print @lines;
close(FILE);
Paul Lalli wrote:
Jon.Macpherson@xxxxxxxxx wrote:
Paul Lalli wrote:
Jon.Macpherson@xxxxxxxxx wrote:
Well, it works from the command line, but not in a browser window......
What is it? (Please quote some context when posting a reply)
What is "not works"? (Please post the actual error description)
The script didn't work, got an internet server error, log file says:
"cannot open due to no such file or directory.
Have you looked in your server logs?
Sorry...... Been programming perl for 5 years, just thought that server
logs was a no-brainer
Have you read the appropriate FAQ?
perldoc -q 500
My CGI script runs from the command line but not the
browser. (500 Server Error)
I have probably read ever standard perl doc, faq, tutorial, from reg.
expressions to object orientation.
When I run the code on the command line, it will open the file from a
mapped drive, but when I run the program as a CGI thru apache, it will
not be able to open the file. I really appreciate help, I have to have
this program working by the 13th of march !!! a newspaper is upgrading
their editorial system to use my software, and its not working.
I am phenomenally amused by this post. You post a poor question, and I
ask four different questions in an attempt to help you. You respond by
frantically telling us how you need the solution immediately, and
completely fail to answer any of my questions.
Did you think I was posting those questions for the hell of it? For my
own satisfaction? If you had taken the time to find the answer to ANY
of those questions, I bet you would have found the answer.
As it is now the 13th of March, I can only hope that your reluctance to
put forth any effort into solving your problem has resulted in some
large problem for your client, thus forcing either A) you to become a
better programmer next time around, or B) you to lose this client, and
thus create a job opportuinity for a better programmer.
Thanks paul, my biggest motivater is revenge...... you gave me the umph
to figure this out. Problem fixed !!!!
Paul Lalli
.
- Follow-Ups:
- Re: Using Files from mapped drives
- From: Paul Lalli
- Re: Using Files from mapped drives
- References:
- Using Files from mapped drives
- From: Jon . Macpherson
- Re: Using Files from mapped drives
- From: Jon . Macpherson
- Re: Using Files from mapped drives
- From: Paul Lalli
- Re: Using Files from mapped drives
- From: Jon . Macpherson
- Re: Using Files from mapped drives
- From: Paul Lalli
- Using Files from mapped drives
- Prev by Date: Perl script to read IIS ftp log file
- Next by Date: RE: Perl script to read IIS ftp log file
- Previous by thread: Re: Using Files from mapped drives
- Next by thread: Re: Using Files from mapped drives
- Index(es):
Relevant Pages
|