当前位置:编程学习 > C#/ASP.NET >>

翻译PHP文件给.NET做网站行业的朋友共享

快速提升Alexa的代码 + Alexa rank cheater


这里用了img的tag伪装所有访客全部安装alexa条

如何用在.NET里面呢?qq:82697180

<?
//[ARC] Alexa Rank Cheater
//
//Author: Stephen Hill - admin@onlinehoster.com - http://www.onlinehoster.com
//
//Date: 14th December 2005
//
//Description:
//Increases your Alexa ranking by hitting your website through proxy servers
//and emulating the use of the alexa 易做图. Alexa service thinks your
//site is suddenly alot more popular and your rank goes up. Simple
//
//How-to:
//Fill proxies.txt with as many proxy servers as you can. They should
//be formatted as IP:PORT with one per line. E.g 10.0.0.1:8080
//
//Upload this file and proxies.txt to your webserver, visit this page
//enter your url in the format of http://www.yourdomain.com and click GO.
?>


<?
@set_time_limit(0);
echo "<title>[ARC] Alexa Rank Cheater</title>
<style type='text/css'>
body {
background-color: black;
font-family: verdana;
color: white;
}

table {
border: 10px dotted white;
border-width: 1px
}

</style>
";

if(!$site){
echo "
<br /><br />
<center>
<table>
<form method='post' action='index.php'>
<tr>
<td>website:<input type='text' name='site' value='http://www.onlinehoster.com'></td>
</tr>
<tr>
<td align='right'><input type='submit' value='GO'></td>
</tr>
</table>
</center>
";
}

if($site){
$alexaurl = "http://209.237.237.101/data/Ae7E31+kj740Ee?cli=10&dat=snba&ver=7.0&url=$site";
$rank = file_get_contents($alexaurl);
preg_match_all("/REACH RANK=(.+?)\/>/is", $rank, $result);
$rank = $result[1];
foreach($rank as $rank){
$rank = str_replace("\"", "", $rank);
}

echo "Current rank for $site: $rank<br /><br />";

$handle = @fopen("proxies.txt", "r");
if ($handle) {
   while (!feof($handle)) {
       $buffer = fgets($handle, 4096);
$data = explode(":", $buffer);
$ip = $data[0];
$port = $data[1];
if($ip){
echo "Connecting to $ip on port $port...";
flush();
$ch = curl_init();
curl_setopt($ch, CURLOPT_URL,$alexaurl);
curl_setopt($ch, CURLOPT_RETURNTRANSFER,1);
curl_setopt($ch, CURLOPT_TIMEOUT,5); //set timeout to 2 so we dont get stuck on dead proxies
curl_setopt($ch, CURLOPT_PROXY, "$ip:$port");
$result = curl_exec($ch);
if(!$result){
echo "<font color='red'>failed</font><br />";
flush();
}else{
echo "<font color='green'>success</font><br />";
flush();
}
}
   }
   fclose($handle);
}

}

?> --------------------编程问答-------------------- 帮顶 --------------------编程问答-------------------- mark --------------------编程问答-------------------- 没有人回答么?
补充:.NET技术 ,  ASP.NET
CopyRight © 2022 站长资源库 编程知识问答 zzzyk.com All Rights Reserved
部分文章来自网络,