Jump to content

directory contents via http


amosglenn

Recommended Posts

Hi-

I'm working on a "connector form" that will ask the user for a url, fetch the contents of that page, replace all the instances of a list of words with links, and write a new file for the user to upload. It's working pretty well so far, but I want to add the ability to give the form a directory (instead of a file) and have it return with a list of files in that directory.

I'm learning a bit of cURL for talking to ther other server via http, but I'm just beginning to learn how to use that library. It seems doable with ftp, but my form doesn't have ftp access to the other servers. I've searched through the php manual and the cURL help, but haven't found any information (or at least information I understand).

Is there a way for http to tell you the names of the files with a directory? Files within directories within directories would be even better.

Is this possible? Can you point me to a place to learn this?

Thanks!
Link to comment
Share on other sites

I'm not sure that's even possible. You have to have the ability to run filesystem functions on the server you're talking to, and I'm about 95% sure you'll have to be running your scripts on that specific server instead of against it.
Link to comment
Share on other sites

This thread is more than a year old. Please don't revive it unless you have something important to add.

Join the conversation

You can post now and register later. If you have an account, sign in now to post with your account.

Guest
Reply to this topic...

×   Pasted as rich text.   Restore formatting

  Only 75 emoji are allowed.

×   Your link has been automatically embedded.   Display as a link instead

×   Your previous content has been restored.   Clear editor

×   You cannot paste images directly. Upload or insert images from URL.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.