I'm trying to connect to the API via PHP and cURL, but I keep coming
up with an error. Below is my code
$username = "
m...@email.com";
$password = "********";
define('POSTURL','
https://360services.sorensonmedia.com/sessions');
define('POSTVARS',"username=".$username."&password=".$password);
$c = curl_init(POSTURL);
var_dump($c);
curl_setopt($c, CURLOPT_RETURNTRANSFER, 1);
curl_setopt($c, CURLOPT_HEADER, 0);
curl_setopt($c, CURLOPT_POST,1);
curl_setopt($c, CURLOPT_POSTFIELDS,POSTVARS);
$content = curl_exec($c);
var_dump($content);
echo $content;
curl_close($c);
Here is the response:
resource(4) of type (curl) bool(false)
any help is greatly appreciated.