Is it possible to download the files in a directory using curl in PHP?
divyakrishnan
20
Junior Poster
Recommended Answers
Jump to PostYes, 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, …
All 2 Replies
Reply to this topic
Be a part of the DaniWeb community
We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.