<php
$qq = "100000"; //qq号码
$pwd = "123456"; //密码
$ch = curl_init();
curl_setopt($ch, curlopt_url, "http://211.139.167.71/waptest/twf/qqportal/rela/updateuserinfo.jsp");
curl_setopt($ch, curlopt_followlocation, 1); //这行是设定curl是否跟随header发送的location,
重要
curl_setopt($ch, curlopt_post, 1);
//curl_setopt($ch, "connection", "keep-alive");
curl_setopt($ch, curlopt_returntransfer,1);
curl_setopt($ch, curlopt_postfields, "qq=".$qq."&pwd=".$pwd."&fromwhere=register");
$return = curl_exec($ch);
curl_close($ch);
echo strstr($return, "postfield") ? "登录失败" : "登录成功";
?>
新闻热点
疑难解答