athlon1600/php-curl-file-downloader

There is no license information available for the latest version (v1.0) of this package.

v1.0 2020-06-07 19:25 UTC

This package is auto-updated.

Last update: 2020-07-07 22:10:51 UTC


README

There's too many code snippets on the Internet on how to do this, but not enough libraries. So I made this.

<?php

use Curl\Client;
use CurlDownloader\CurlDownloader;

$browser = new Client();
$downloader = new CurlDownloader($browser);

$downloader->download("https://download.ccleaner.com/cctrialsetup.exe", function ($filename) {
    return './2020-06-07-' . $filename;
});

Installation

composer require athlon1600/php-curl-file-downloader

Links