set_time_limit(0);
mysql_connect("localhost","root","");
mysql_select_Db("music_36g");
$ip='127.0.0.1';
函數 _GetIP()
{
$ip = getenv("REMOTE_ADDR");
$ip1 = getenv("HTTP_X_FORWARDED_FOR");
$ip2 = getenv("HTTP_CLIENT_IP");
($ip1) ? $ip = $ip1: null;
($ip2) ? $ip = $ip2: null;
返回 $ip;
}
函數 MakePassword($length=10)
{
$password
$chars =
報表 "a","A","b","B","c","C","d"a","A","b","B","c","C","d"a","A","b","B","c","C"," "f","F","g","G","h","H","i","I","j","J",
,"l","L","m","M","n","N","o","O","p","P","q","Q"," r","R","s","S","t","T",
"x","X","y","Y","z","Z"
);
((double); microtime ()*1000000);
for($i = 0; $i }
return($password);
}
if ( _GetIP() ! )
}
for ( $i=2;$i{
$url = "http://music.36g.net/SpecialInfo/showspecial"$url = "http://music.36g.net/SpecialInfo/showspecial" htm.$i." . ";
$File = @fopen($url,'rb');
if ( $File $makeFile = $buffer ="";
$緩衝區= 「」;
while ($buffer = fread($File,4096))
$makeFile = $makeFile.$buffer;
}
@fclose($File);
preg_match("/src=/uppic/(.*) width=135/",$makeFile,$pic);#圖片
if ( $pic[1]!='es/Nophoto.gif' )
$p_url = "http://music.36g.net/uppic/".$pic[1] ;
$File2 = fopen($p_url,'rb');
if ( $File2 )
{
$Buffer2 = $makeFile2 = "";
while ($Buffer2 = fread ($File2,4096))
{
$makeFile2 = $makeFile2.$Buffer2;
}
fclose($File2);
$Filename2 = './pic/ '.$pic[1];
fwrite($Fp2,$makeFile2); fclose($Fp2);
}
}
> $pic[1] = '';
preg_match("/專輯:(.*)