I have a problem I'm using a PHP under 5.5, so I do not have the curl_file_create
function to use, even though I'm not able to send could you help me?
public function enviaArquivo($arquivo){
$ch = curl_init('https://site.com.br/upload_direto?token=xxxxxxxxxxxxx');
curl_setopt_array($ch, [
CURLOPT_RETURNTRANSFER => true,
CURLOPT_POST => true,
CURLOPT_POSTFIELDS => [
'File' => "@/var/www/site.com.br/sistema/php/cron/".$arquivo,
'Token'=> 'xxxxxxxxxxxxxxxxxxxxxxxxxxxxx',
]
]);
$resposta = curl_exec($ch);
echo $resposta;
curl_close($ch);
}