Hey all, I'm in a fix and am not able to solve this problem! I have a file located on a server machine and I wanna read that file! the server name is server.safl.umn.edu and, if I specify this $file = '\\server.safl.umn.edu\common\cellis\safl weather\saf_wthr.dat'; $fp = fopen($file,"r") it gives me the following error Warning: fopen(\server.safl.umn.edu\common\cellis\safl weather\saf_wthr.dat) [function.fopen]: failed to open stream: No such file or directory in C:\websites\techtest.safl.umn.edu\Vivek\demo3.php on line 54 The access permission settings are perfect, but it just doesnt work!
Vivsriaus, welcome to DP. I believe the problem is that you aren't giving an absolute URL to the file. Try using $file = "c:\websites\techtest.safl.umn.edu\common\cellis\safl weather\saf_wthr.dat", if this is the asbolute path of course.
I have no experience with php + windows + remote access, but you might want to check you back slashes. try $file = '\\\\server.safl.umn.edu\\common\\cellis\\safl weather\\saf_wthr.dat'; $fp = fopen($file,"r") good luck
Hey pals, Thnx for the replies! I tried everything! givin the full path as well as addin more escape characters! but, in vain! Am not sure wht is happening
You probably should supply us with additional error messages. Have you checked if the file even exists?
Are spaces allowed in the "safl weather" part? You could try urlencode to make sure it is formatted OK