您的位置:首页 > 编程语言 > PHP开发

php灌水

2016-05-20 10:27 447 查看
<?php

$data=array('name'=>'paul','mail'=>'paulversion@163.com')

$data=http_build_query($data);

$opts=array(

'http'=>array(

'method'=>'Post',

'header'=>"Content-type:application/x-www-form-urlencode\r\n",

'Content-Length':".strlen($data)."\r\n",

'Cookie':'',//现在浏览器中提交获取相应的Cookie User_Agent,Referer的值

'User-Agent':'',

'Referer':'',

'content'=>$data

)

)

$context=stream_context_create($opts);

$html=file_get_contents(url,false,$context)//url为灌水需要提交的地址

?>
内容来自用户分享和网络整理,不保证内容的准确性,如有侵权内容,可联系管理员处理 点击这里给我发消息
标签: