怎么用curl抓取.net的asmx的数据 我想用curl 获取 asmx传递出来的数据,http://218.5.78.87/Game2/ws.asmx/GetBuildings但是就是不行,请问怎么办谁给段代码要用到上面技术??找了一下soap.但是没实现,谢谢各位达人 解决方案 » 免费领取超大流量手机卡,每月29元包185G流量+100分钟通话, 中国电信官方发货 GetBuildings这个函数需要哪些参数? httpwatch查看的参数 (Content) = {}或者 (Content) = {"id":"35"} 你既然知道webservice有个GetBuildings函数,应该有相关的连接参数文档吧。 没有啊,我们就是要抓取别人的数据,做游戏外挂,以前用curl 都能顺利的搞定但是遇到这个游戏是dot net 做的,就郁闷了还是webservice 可以post 数据吗?? 我不知道这个能不能用PHPcurl实现。请各位高手 帮帮忙一个CURL登陆的,<?php $geturl = "http://222.241.150.195:8021/Game2/ws.asmx/GetCastle"; $loginurl = "http://218.5.78.87/youjia.aspx?user_id=139788&time=2009-9-11&server_id=1801&sign=987AFAC01253EE0FE5178F6A2E189CD8&gameType=5"; function getContent($url,$iscookie=false,$param=''){ //echo $_SESSION['id']; $cookie_file = "D:\wamp\www\shikong\cookies.txt"; $ch = curl_init(); curl_setopt($ch,CURLOPT_REFERER,0); curl_setopt($ch,CURLOPT_FOLLOWLOCATION,1); curl_setopt($ch, CURLOPT_URL, $url); curl_setopt($ch, CURLOPT_HEADER, 0); curl_setopt($ch, CURLOPT_RETURNTRANSFER,1); curl_setopt($ch, CURLOPT_POST, 1); if($param) curl_setopt($ch, CURLOPT_POSTFIELDS, $param); if($iscookie) curl_setopt($ch, CURLOPT_COOKIEJAR, $cookie_file); curl_setopt($ch,CURLOPT_COOKIEFILE, $cookie_file); curl_setopt($ch, CURLOPT_NOBODY, 0); curl_setopt($ch,CURLOPT_TIMEOUT,120); $_source = curl_exec($ch); curl_close($ch); return $_source; } getContent($loginurl,true); //$ss = getContent($geturl,true,http_build_query($post)); //var_dump($ss); ?> 这个怎么解密 linux已經安裝openssl,如何重新編譯php支持openssl模塊? 诚聘网站PHP工程师,主要为网站B/S系统程序开发 如何解决MYSQL简断连接出现错误的情况? 大连的PHPer好找工作吗?谢谢 动态表格边框叠加? 定时window.location.reload()与setInterval()的比较 再问个:怎么样把判断提交页面的地址!3KS! 关于PHP正则问题 如何在页面显示记录呢? 視頻隨即抽出 根据IP得到用户在哪个洲
或者 (Content) = {"id":"35"}
做游戏外挂,以前用curl 都能顺利的搞定
但是遇到这个游戏是dot net 做的,就郁闷了
还是webservice 可以post 数据吗??
我不知道这个能不能用PHPcurl实现。
请各位高手 帮帮忙一个CURL登陆的,
<?php
$geturl = "http://222.241.150.195:8021/Game2/ws.asmx/GetCastle";
$loginurl = "http://218.5.78.87/youjia.aspx?user_id=139788&time=2009-9-11&server_id=1801&sign=987AFAC01253EE0FE5178F6A2E189CD8&gameType=5";
function getContent($url,$iscookie=false,$param=''){
//echo $_SESSION['id'];
$cookie_file = "D:\wamp\www\shikong\cookies.txt";
$ch = curl_init();
curl_setopt($ch,CURLOPT_REFERER,0);
curl_setopt($ch,CURLOPT_FOLLOWLOCATION,1);
curl_setopt($ch, CURLOPT_URL, $url);
curl_setopt($ch, CURLOPT_HEADER, 0);
curl_setopt($ch, CURLOPT_RETURNTRANSFER,1); curl_setopt($ch, CURLOPT_POST, 1);
if($param)
curl_setopt($ch, CURLOPT_POSTFIELDS, $param);
if($iscookie)
curl_setopt($ch, CURLOPT_COOKIEJAR, $cookie_file);
curl_setopt($ch,CURLOPT_COOKIEFILE, $cookie_file);
curl_setopt($ch, CURLOPT_NOBODY, 0);
curl_setopt($ch,CURLOPT_TIMEOUT,120);
$_source = curl_exec($ch);
curl_close($ch);
return $_source;
}
getContent($loginurl,true);
//$ss = getContent($geturl,true,http_build_query($post));
//var_dump($ss);
?>