I'd like to know what the http_build_query
function in php is for.
I read the manual, but it became vague to me.
Is it right to use it within this context?
$cURL = curl_init('http://teste');
curl_setopt($cURL, CURLOPT_RETURNTRANSFER, true);
$dados = array(
'NMCLIENTE' => $nome_lead,
'DSEMAIL' => $email_lead,
'NRTELEFONE' => $telefone_lead,
'DSINTERESSE' => $meio_captacao,
'DSMENSAGEM' => $mensagem
);
curl_setopt($cURL, CURLOPT_POST, true);
curl_setopt($cURL, CURLOPT_POSTFIELDS, http_build_query($dados));
$resultado = curl_exec($cURL);
curl_close($cURL);