3
Contributors
2
Replies
3
Views
4 Years
Discussion Span
Last Post by diafol
0

Yes, you can. Through the FTP protocol. Here's a sample directory listing, then with regards to downloading the contents, you can use ftp commands to download the contents after parsing the directory list

$curl = curl_init();
$ftpURL = "ftp://localhost/"
$ftpUsername = "username"
$ftpPassword = "password"

curl_setopt($curl, CURLOPT_URL, $ftpURL);
curl_setopt($curl, CURLOPT_USERPWD, $ftpUsername . ":" . $ftpPassword);
curl_setopt($curl, CURLOPT_RETURNTRANSFER, 1);

$result = curl_exec ($curl);

//Parse your result then use ftp to download the content

Edited by gon1387

This topic has been dead for over six months. Start a new discussion instead.
Have something to contribute to this discussion? Please be thoughtful, detailed and courteous, and be sure to adhere to our posting rules.