我想请求通过curl登录Adobe Connect。
$ch = curl_init('https://emea2cps.adobeconnect.com/api/xml?action=login&login=nurgasemetey@gmail.com&password=D742455B61/');
curl_exec($ch);
$info= curl_getinfo($ch);
echo 'passed' . $info['total_time'] . ' secconds ' . $info['url'] . '------ and http-code'. $info['http_code'];
curl_close($ch);
但回应是这样的
passed 0.078 seconds https://emea2cps.adobeconnect.com/api/xml?action=login&login=nurgasemetey@gmail.com&password=D742455B61/------ and http-code 0
我推断它没有正确连接,但在浏览器上返回正确。哪里可能有问题?
关于
添加此参数
curl_setopt($ch,CURLOPT_SSL_VERIFYPEER, false);
代码...
<?php
$ch = curl_init('https://emea2cps.adobeconnect.com/api/xml?action=login&login=nurgasemetey@gmail.com&password=D742455B61/');
curl_setopt($ch,CURLOPT_SSL_VERIFYPEER, false);
curl_exec($ch);
$info= curl_getinfo($ch);
echo 'passed' . $info['total_time'] . ' secconds ' . $info['url'] . '------ and http-code'. $info['http_code'];
curl_close($ch);
OUTPUT :
passed5.922 secconds https://emea2cps.adobeconnect.com/api/xml?action=login&login=nurgasemetey@gmail.com&password=XXXXXX/------ and http-code200