Cannot Access a File

PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!

Moderator: General Moderators

Post Reply
smgrisw
Forum Newbie
Posts: 1
Joined: Mon Feb 05, 2007 3:21 pm

Cannot Access a File

Post by smgrisw »

All,

I have an issue that I cannot resolve. I have a program that runs on a windows machine that opens a file on a network share and processes the contents of the file. This process works fine when I run the job by clicking on the program. When I run the program throught a PHP script using exec an error message saying that the the file cannot be found. If I run this same program using exec except that I point to the same file that has been copied to a local drive I have no problem opening it and processing it.

Has anyone come across this before?

Regards,

Scott
User avatar
feyd
Neighborhood Spidermoddy
Posts: 31559
Joined: Mon Mar 29, 2004 3:24 pm
Location: Bothell, Washington, USA

Post by feyd »

The network share probably isn't readable to the user PHP is being run as, or PHP doesn't understand it.

You could use a batch file to request the shared file.
Post Reply