Уже голову поломал, почему не работает curl. Точнее он то работает то нет. Например вот пытаюсь авторизироваться: $url = "http://www.textsale.ru/login.php"; $ch = curl_init(); curl_setopt($ch, CURLOPT_URL, $url); curl_setopt($ch, CURLOPT_COOKIESESSION, TRUE); curl_setopt($ch, CURLOPT_COOKIEFILE, "cookiefile"); curl_setopt($ch, CURLOPT_FOLLOWLOCATION, true); curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1); curl_setopt($ch, CURLOPT_USERAGENT, 'Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1)'); curl_setopt($ch, CURLOPT_POST, 1); curl_setopt($ch, CURLOPT_POSTFIELDS, "nickform=ЛОГИН&passwordform=ПАРОЛЬ"); $result = curl_exec($ch); curl_close($ch); echo $result; Вчера все работало, сегодня просто пустая страница. Кто знает в чем может быть дело?
Ответ вот: HTTP/1.1 302 Found Date: Wed, 21 Oct 2009 16:28:00 GMT Server: Apache/2.0.58 X-Powered-By: PHP/5.2.6 Set-Cookie: nick= ; expires=Tue, 27-Oct-2009 11:21:20 GMT Set-Cookie: userid=43590; expires=Tue, 27-Oct-2009 11:21:20 GMT Set-Cookie: password=8bc72fc517a7d1fda02ceda7c0f13430; expires=Tue, 27-Oct-2009 11:21:20 GMT Location: Content-Length: 14 Content-Type: text/html; charset=windows-1251 Content-Language: ru