20小時讀一次目標的站,可以自己修改,看下就明白怎麼弄其他站了,很簡單的.
chuanqi.php //小偷
extract($_GET);extract($_POST);
$clinchurl = "http://www.haosf.com"; //目標站
$url = $clinchurl.$domain;
$fp=@fopen($url,"r") or die("timeout");//判斷網頁能否開啟
$fcontents = file_get_contents($url);
//echo $fcontents;
if(eregi('傳奇伺服器名(.*)>下一頁',$fcontents,$regs))
{
//上面的(.*)是你要得到的內容-列表的地方
$clinch = "
| 傳奇伺服器名 | ".$regs[1].""; //把得到的內容的html補齊,自己發揮 }//END IF $clinch=str_replace('
| ','你自己的廣告',$clinch); //一連串的str_replace,替換掉不需要的東西,比如廣告或圖片 ?> include "lanmu.php"; //欄目列表 ?> //利用這個判斷更新html頁面 include "foot.php"; ?> make.php //產生html.緩衝 extract($_GET);extract($_POST); $url="http://xxxxxxx.com/chuanqi.php"; if(!$file){ $file="index.html";$url="http://xxxxxxxxxxxx.com/chuanqi.php"; } /*自己加判斷這個$url的語句,來賦予 $file不同的名字-----------》產生不同的html名字 比如: if($file="wow.html"){ //$file是在人們訪問html頁面時由iframe傳遞過來的 $url="http://xxxxxx/wow.php" //相應的動態網頁面 } */ $path=$file; $cache_filetime = filemtime($path); if (time() - $cache_filetime <= 72000) { //** the cache is not expire echo "還沒有必要更新"; }else{ $fp=@fopen($url,"r") or die("timeout");//判斷網頁能否開啟 $fcontents = file_get_contents($url); $handle=fopen($path,'w'); //寫入方式開啟路徑 fwrite($handle,$fcontents); //把剛才替換的內容寫進產生的HTML檔案 fclose($handle); echo "done"; } ?>