管理员
   
论坛积分
分
威望 点
贡献值 个
金币 枚
|
$postdata = http_build_query($data);( @5 Q$ S4 ^9 [' `8 |6 P- u1 p1 ^
; Q" x$ R7 Q$ @1 l8 ~4 n' l
$opts = array (
3 Q, f O1 ]; ~; I V 'http' => array (4 w' C1 C- V. \2 T8 h. L# h
'method' => 'POST',% J0 P' s# e/ L% }) L- q/ K
'header'=> "Content-type: application/x-www-form-urlencodedrn",
, R! b& ^% n$ Q# d8 s( s z8 P "Content-Length: " . strlen($data) . "rn",' Y: J5 D& E# M1 Y( g
'content' => $postdata
" u( r8 u! _5 g* r/ W) x8 h" _ )! P/ T" d2 Z% b8 m: L
);5 E: M* h. J( G0 x& y0 |
( p; R5 ?( I3 Z( Y# [ $context = stream_context_create($opts); J) S2 j) d/ x" R! ?
$html = file_get_contents($url, false, $context);
' ]. K7 ?3 B4 m" r
) m4 {# s+ k0 c# e* Y |
|