php 模拟POST提交的2种方法详解
一、通过curl函数复制代码 代码如下:$post_data = array();$post_data[‘clientname’] = “test08”;$post_data[‘clientpasswd’] = “test08”;$post_data[‘submit’] = “submit”;$url=’http://xxx.xxx.xxx.xx/xx/xxx/top.php’;$o=””;foreach ($post_data as $k=>$v){ $o.= “$k=”.urlencode($v).”&”;}$post_data=substr($o,0,-1);$ch = curl_
用户评论