how to access folders

Discussion in 'PHP' started by dizyn, Mar 7, 2009.

  1. #1
    Hi

    I want to access folders on other server using php code, can i do this?

    I have two server and I want to see if folder abc exists on 2nd server, how can i do this?

    For example I have two servers

    Server1 and Server2

    I am on Server1 and want to check if folder xyz is present on Server2

    Thanks
     
    dizyn, Mar 7, 2009 IP
  2. exodus

    exodus Well-Known Member

    Messages:
    1,900
    Likes Received:
    35
    Best Answers:
    0
    Trophy Points:
    165
    #2
    You wouldn't be able to access the directory directly from remote because of security, but doing cUrl and trying to load http://site.com/directory/file.html then seeing if that returns a 404 or all clear then you can tell if a file exists in that directory in which that directory does, but as for seeing that directory exists without direct access to that server then no, because of security.
     
    exodus, Mar 7, 2009 IP