$cookie_jar = tempnam('./cookie','123');
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL, "http://search.neea.edu.cn/Imgs.do?act=verify&t=0.8841180045674784");
curl_setopt($ch, CURLOPT_REFERER, "http://search.neea.edu.cn/QueryMarkUpAction.do?act=doQueryCond&sid=300&pram=results");
curl_setopt($ch, CURLOPT_HEADER, 0);
curl_setopt($ch, CURLOPT_RETURNTRANSFER, 1);
curl_setopt($ch, CURLOPT_COOKIEJAR, $cookie_jar);
$img = curl_exec($ch);
curl_close($ch);
$img1 = base64_encode($img);
$img2 = base64_decode($img1);
file_put_contents('./img.png', $img2);
echo "<input type="hidden" id="cookie" value="".$cookie_jar."">";
?>
近期评论