Warning: curl_setopt(): Unable to access
11
●1.942
- 12-12-2007, 10:51:50Kimlik doğrulama veya yönetimden onay bekliyor.hata veren Betiği Buraya Yazarsan Daha Çabuk Sorunu Çözebiliriz
sanırım php ile curl oturumu Açıyorsun
hata Verin satırın başına // Bırakırsan sorun Çözülür Sunucularda Bazen CURLOPT_FOLLOWLOCATION
CURLOPT_SSL_VERIFYPEER
izin olmuyor - 12-12-2007, 10:54:53Üyeliği durduruldu
<?php $url = 'http://www.livescore.com/default.dll'; $cookie_file_name = "/tmp/cookie.txt"; $curl = curl_init(); curl_setopt($curl, CURLOPT_COOKIEJAR, $cookie_file_name); curl_setopt($curl, CURLOPT_FOLLOWLOCATION, 1); curl_setopt($curl, CURLOPT_URL, $url); curl_setopt($curl, CURLOPT_RETURNTRANSFER, true); curl_setopt($curl, CURLOPT_HEADER, true); $str = curl_exec($curl); unset($curl); $ch = curl_init(); curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1); curl_setopt($ch, CURLOPT_COOKIEFILE, $cookie_file_name); curl_setopt($ch, CURLOPT_URL, $url); $buf2 = curl_exec($ch); curl_close($ch); $pos1 = '<tr bgcolor="#333333"><td class="title" colspan="4" height="18"> <b>'; $pos2 = '<tr bgcolor="#111111"><td colspan="4" height="4"></td></tr></table>'; $buf3 = substr($buf2, strpos($buf2, "$pos1")); $buf3 = substr($buf3, 0, strpos($buf3, "$pos2")); echo "$buf3"; ?>
demo http://blogcum.li/1/veri.php dün çekmeyen site büğün çekiyor anlamıyorum
- 12-12-2007, 11:13:59sorununun sebebi bu değil ama her ihtimale karsı bos veya php olarak browser yollayacağın yere ie gibi görünmek iyidir demek istedimstrhost adlı üyeden alıntı: mesajı görüntüle
curl_setopt($ch, CURLOPT_USERAGENT, "Mozilla/5.0 (Windows; U; Windows NT 5.1; en-US; rv:1.8.1.1) Gecko/20061204 Firefox/2.0.0.1");