跟蹤了一下,我想這個fileserve接口已經完全變化了9 Z6 c2 q2 s9 R k c
$getsessionurl = "http://www.fileserve.com/upload-track.php";7 m' I' _- o) P( Y# H) I f
$reffer = "http://www.fileserve.com/upload-file.php";
; Y4 {8 J" l2 W3 O# b $ch = curl_init();( k$ c* Q. I" n
curl_setopt($ch, CURLOPT_URL, $getsessionurl);
( r9 ]& h# j1 C+ y. q! ?7 G W curl_setopt($ch, CURLOPT_USERAGENT, $agent);+ A/ i; l3 _0 O
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);! z! h( }( q$ F, ^
curl_setopt($ch, CURLOPT_FOLLOWLOCATION, 1);
N6 G' b/ n! p1 b0 t curl_setopt($ch, CURLOPT_HEADER, 1);
, S, H" J2 H1 x2 \$ M7 Z" K2 r+ h curl_setopt($ch, CURLOPT_REFERER, $reffer);
+ Y! {4 F5 J) Y& [2 d) {& r curl_setopt($ch, CURLOPT_COOKIEFILE, $cookie_file_path);
+ S. t& F; `. Q, K! A# K! e$ B curl_setopt($ch, CURLOPT_COOKIEJAR, $cookie_file_path);
& q6 J- S' m8 j6 F $result = curl_exec($ch);$ {& {" _ p7 H g) e! d
" E' L- T9 v' s: P5 \- d
echo $result;
6 k# J* T/ [: y( g0 @" `" o p: y $parse=explode('Id":"',$result);/ m( L$ j' p! z- f8 I- P6 X
7 b( w2 ~( k! j' [5 j5 R
返回的是:HTTP/1.1 410 Gone X-Powered-By: PHP/5.3.1 Content-type: text/html Content-Length: 0 Date: Tue, 20 Sep 2011 02:18:44 GMT Server: fileserve5 p4 R$ W% i% n* A! Z9 d
根本沒有"Id",上面upload-file.php返回的情況類似 |