我正在尝试将 post 参数发送到 url http://judis.nic.in/supremecourt/DateQry.aspx
并在 php 中阅读响应...如何发送和阅读响应...!
提前致谢..
我的代码...如下评论
<?php
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, "http://judis.nic.in/supremecourt/DateQry.aspx");
curl_setopt($ch, CURLOPT_HEADER, 0);
curl_setopt($ch, CURLOPT_POST, 1);
curl_setopt($ch, CURLOPT_POSTFIELDS, "button=Submit");
curl_setopt($ch, CURLOPT_POSTFIELDS, "ddlday1=01");
curl_setopt($ch, CURLOPT_POSTFIELDS, "ddlday2=31");
curl_setopt($ch, CURLOPT_POSTFIELDS, "ddlmonth1=01");
curl_setopt($ch, CURLOPT_POSTFIELDS, "ddlmonth2=01");
curl_setopt($ch, CURLOPT_POSTFIELDS, "ddlreport=A");
curl_setopt($ch, CURLOPT_POSTFIELDS, "ddlyear1=2013");
curl_setopt($ch, CURLOPT_POSTFIELDS, "ddlyear2=2013");
curl_setopt($ch, CURLOPT_FOLLOWLOCATION, 1);
$response=curl_exec($ch);
echo $response;
curl_close($ch);
?>