Skip to content

14.01.0

tagged this 13 Jan 11:12
Unified interface for adding files to CURLOPT_POSTFIELDS
 'field' => Sledgehammer\Curl::file('/path/to/filename')

Instead of:

PHP < 5.5
 'field' => '@/path/to/filename'
PHP >= 5.5
 'field' => curl_file_create('/path/to/filename')
or
 'field' => new \CURLFile('/path/to/filename')
Assets 2