Jump to content


Photo

Accessing Remote Directories


  • Please log in to reply
1 reply to this topic

#1 sammermpc

sammermpc
  • Members
  • PipPip
  • Member
  • 16 posts

Posted 12 June 2006 - 10:50 PM

I'm working on a php parser that has to batch process many files in different directories, some mounted on different file servers. Everything goes well, and during testing, everything works perfectly for LOCAL directory access. Unforunately, when I use opendir with a URL (opendir(http://ect...), I get the error:

[!--quoteo--][div class=\'quotetop\']QUOTE[/div][div class=\'quotemain\'][!--quotec--]Warning: opendir(http://somewebsite.s.../folder/folder/) [function.opendir]: failed to open dir: not implemented in /home/myname/public_html/folder/file.php on line 229[/quote]

I've been browsing around the web and most people's problems with this error seems to be that they are using the web address syntax when they should be using the local folder one. I am pretty sure this is not my problem, as I need to log on to a remote server to obtain the necessary files (it would be impractical to move them).

So what gives? I've seen some vague talk about changed within config.php, though nothing conclusive.


#2 sammermpc

sammermpc
  • Members
  • PipPip
  • Member
  • 16 posts

Posted 12 June 2006 - 11:12 PM

[!--quoteo(post=383004:date=Jun 12 2006, 05:50 PM:name=sammermpc)--][div class=\'quotetop\']QUOTE(sammermpc @ Jun 12 2006, 05:50 PM) View Post[/div][div class=\'quotemain\'][!--quotec--]
I'm working on a php parser that has to batch process many files in different directories, some mounted on different file servers. Everything goes well, and during testing, everything works perfectly for LOCAL directory access. Unforunately, when I use opendir with a URL (opendir(http://ect...), I get the error:
I've been browsing around the web and most people's problems with this error seems to be that they are using the web address syntax when they should be using the local folder one. I am pretty sure this is not my problem, as I need to log on to a remote server to obtain the necessary files (it would be impractical to move them).

So what gives? I've seen some vague talk about changed within config.php, though nothing conclusive.
[/quote]


UPDATE: I think the central issue is that though fopen can work with both paths and urls, it appears that opendir cannot, so that even for the purpose of opening a remote directory you must use fopen. That sound likely to anyone?





0 user(s) are reading this topic

0 members, 0 guests, 0 anonymous users