首页 新闻 会员 周边

谁懂PHP,又懂.NET的?

0
[已关闭问题]
<P>这是一段PHP能够迅速提高&nbsp;Alexa 排名的代码,谁能给帮忙翻译下?给.NET做网站的朋友一起共享。</P> <P>QQ:82697180 MSN:LISHUNHU@MSN.COM</P> <P>&lt;?<BR>//[ARC] Alexa Rank Cheater<BR>//<BR>//Author: Stephen Hill - <A href="mailto:admin@onlinehoster.com">admin@onlinehoster.com</A> - <A href="http://www.onlinehoster.com/">http://www.onlinehoster.com</A><BR>//<BR>//Date: 14th December 2005<BR>//<BR>//Description:<BR>//Increases your Alexa ranking by hitting your website through proxy servers<BR>//and emulating the use of the alexa toolbar. Alexa service thinks your<BR>//site is suddenly alot more popular and your rank goes up. Simple<BR>//<BR>//How-to:<BR>//Fill proxies.txt with as many proxy servers as you can. They should<BR>//be formatted as IP:PORT with one per line. E.g 10.0.0.1:8080<BR>//<BR>//Upload this file and proxies.txt to your webserver, visit this page<BR>//enter your url in the format of <A href="http://www.yourdomain.com/">http://www.yourdomain.com</A> and click GO.<BR>?&gt;</P> <P><BR>&lt;?<BR>@set_time_limit(0);<BR>echo "&lt;title&gt;[ARC] Alexa Rank Cheater&lt;/title&gt;<BR>&lt;style type='text/css'&gt;<BR>body {<BR>background-color: black;<BR>font-family: verdana;<BR>color: white;<BR>}</P> <P>table {<BR>border: 10px dotted white;<BR>border-width: 1px<BR>}</P> <P>&lt;/style&gt;<BR>";</P> <P>if(!$site){<BR>echo "<BR>&lt;br /&gt;&lt;br /&gt;<BR>&lt;center&gt;<BR>&lt;table&gt;<BR>&lt;form method='post' action='index.php'&gt;<BR>&lt;tr&gt;<BR>&lt;td&gt;website:&lt;input type='text' name='site' value='http://www.onlinehoster.com'&gt;&lt;/td&gt;<BR>&lt;/tr&gt;<BR>&lt;tr&gt;<BR>&lt;td align='right'&gt;&lt;input type='submit' value='GO'&gt;&lt;/td&gt;<BR>&lt;/tr&gt;<BR>&lt;/table&gt;<BR>&lt;/center&gt;<BR>";<BR>}</P> <P>if($site){<BR>$alexaurl = "<A href="http://209.237.237.101/data/Ae7E31+kj740Ee?cli=10&amp;dat=snba&amp;ver=7.0&amp;url=$site">http://209.237.237.101/data/Ae7E31+kj740Ee?cli=10&amp;dat=snba&amp;ver=7.0&amp;url=$site</A>";<BR>$rank = file_get_contents($alexaurl);<BR>preg_match_all("/REACH RANK=(.+?)\/&gt;/is", $rank, $result);<BR>$rank = $result[1];<BR>foreach($rank as $rank){<BR>$rank = str_replace("\"", "", $rank);<BR>}</P> <P>echo "Current rank for $site: $rank&lt;br /&gt;&lt;br /&gt;";</P> <P>$handle = @fopen("proxies.txt", "r");<BR>if ($handle) {<BR>&nbsp;&nbsp; while (!feof($handle)) {<BR>&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp; $buffer = fgets($handle, 4096);<BR>$data = explode(":", $buffer);<BR>$ip = $data[0];<BR>$port = $data[1];<BR>if($ip){<BR>echo "Connecting to $ip on port $port...";<BR>flush();<BR>$ch = curl_init();<BR>curl_setopt($ch, CURLOPT_URL,$alexaurl);<BR>curl_setopt($ch, CURLOPT_RETURNTRANSFER,1);<BR>curl_setopt($ch, CURLOPT_TIMEOUT,5); //set timeout to 2 so we dont get stuck on dead proxies<BR>curl_setopt($ch, CURLOPT_PROXY, "$ip:$port");<BR>$result = curl_exec($ch);<BR>if(!$result){<BR>echo "&lt;font color='red'&gt;failed&lt;/font&gt;&lt;br /&gt;";<BR>flush();<BR>}else{<BR>ec
问题补充: 居然有字数限制,没有贴完 下载地址:http://onlinehoster.com/blog/wp-content/uploads/2006/09/alexa-rank-cheater1.zip
李顺虎的主页 李顺虎 | 初学一级 | 园豆:0
提问于:2008-03-12 10:34
< >
分享
其他回答(3)
0
有个人,神!!
xiaohc | 园豆:23 (初学一级) | 2008-03-12 10:57
0
...... Alexa排名不是几行代码就能左右地...
孙英雄 | 园豆:857 (小虾三级) | 2008-03-12 13:18
0
有没有哪段代码能提升百度/Google排名的?
deerchao | 园豆:8367 (大侠五级) | 2008-03-12 22:42
0
一个HttpWebRequest 的简单应用,每次访问(GET)之前别忘记切换代理。 HttpWebRequest loHttp = (HttpWebRequest) WebRequest.Create(“http://209.237.237.101/data/Ae7E31+kj740Ee?cli=10&dat=snba&ver=7.0&url=http://blog.rubypdf.com”); loHttp.Proxy = new WebProxy("192.168.1.1", 8080); loHttp.Method = "GET"; // *** Set any header related and operational properties loHttp.Timeout = 5000; // 5 secs //这个参考IE或者FireFox所使用的吧,这里懒得贴了。 loHttp.UserAgent = "Code Sample Web Client"; // *** Return the Response data HttpWebResponse loWebResponse = (HttpWebResponse) loHttp.GetResponse(); //下面自己看着处理输出吧
RubyPDF | 园豆:170 (初学一级) | 2008-03-13 00:06
清除回答草稿
   您需要登录以后才能回答,未注册用户请先注册