管理员
   
论坛积分
分
威望 点
贡献值 个
金币 枚
|
$postdata = http_build_query($data);
$ b: d, q9 V6 P6 V) ~0 |9 C8 o3 n" \
$opts = array (
2 F- m4 B% G( x 'http' => array (
8 c8 X# | W' e* k9 K' u; l/ r 'method' => 'POST',
2 n$ n( d4 c% l% s! l 'header'=> "Content-type: application/x-www-form-urlencodedrn",
2 Q2 K4 z6 C; n3 v0 E "Content-Length: " . strlen($data) . "rn",
9 x% `$ L" {) [0 r3 B 'content' => $postdata
6 e: u( ?( X+ `* y )
8 O: U. B$ W. t% ]7 p1 L );
) Q6 @- ]* }5 z0 y; W. Z/ r) [6 d+ B
$context = stream_context_create($opts);+ H/ c( ]8 g0 ]
$html = file_get_contents($url, false, $context); 8 ^! p% s, u j3 w9 L# D( ~
+ D! L5 d. K' E8 P; N$ M' ^
|
|