Copy code The code is as follows:
$title='Script Home';
$hello='jb51.net!';
$file=file_get_contents('http://www.baidu.com');
$file=iconv("gbk//IGNORE","utf- 8",$file);
//echo $file;
echo strpos($file,'
');
echo substr($file,strpos($file,'< title>')+7,strpos($file,''-strpos($file,'')+7));
$file=str_replace(array('Baidu ','{hello}'),array($title,$hello), $file);
?>
The following is the thief program code used by Yuhai. You can read more. Script House provides a variety of thief programs.
Copy code The code is as follows:
function _url($Date){
ch = curl_init();
$timeout = 5;
curl_setopt ($ch, CURLOPT_URL, "$Date");
curl_setopt ($ch, CURLOPT_RETURNTRANSFER, 1);
curl_setopt ($ch , CURLOPT_USERAGENT, "Mozilla/4.0 (compatible; MSIE 6.0; Windows NT 5.1; SV1)");
curl_setopt ($ch, CURLOPT_CONNECTTIMEOUT, $timeout);
$contents = curl_exec($ch);
curl_close($ch);
return $contents;
}
$url="http://www.jb51.net";
$contents.=_url($url);
echo $contents; //Output content
?>
http://www.bkjia.com/PHPjc/320996.htmlwww.bkjia.comtruehttp: //www.bkjia.com/PHPjc/320996.htmlTechArticleCopy the code as follows: ?php $title='Script Home'; $hello='jb51.net! '; $file=file_get_contents('http://www.baidu.com'); $file=iconv("gbk//IGNORE","utf-8",$file); //echo $file;.. .
Statement:The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn