Google PageRank Script
Welcome to the home of the Google PageRank script.
You’ll find all the information and code you need here:
- History of the PageRank Script by HM2K
- Find the PageRank Scripts Source Code on GitHub in various languages
- The PageRank Viewer website
- Get the Official PEAR Services PageRank package
Please feel free to leave your comments about PageRank below.
Warning: Declaration of Social_Walker_Comment::start_lvl(&$output, $depth, $args) should be compatible with Walker_Comment::start_lvl(&$output, $depth = 0, $args = Array) in /Users/wade/Sites/hm2k.org/wp-content/plugins/social/lib/social/walker/comment.php on line 18
Warning: Declaration of Social_Walker_Comment::end_lvl(&$output, $depth, $args) should be compatible with Walker_Comment::end_lvl(&$output, $depth = 0, $args = Array) in /Users/wade/Sites/hm2k.org/wp-content/plugins/social/lib/social/walker/comment.php on line 42
You are a genius!!!
It finally worked on my weird server!! 😀 Thanks man!
It does not work on my server. I downloaded the file pagerank.phps then change to pagerank.php and upload to my server and run it.But it display the blank page.Why does it happen like that?
stars, i’d check your apache access/error logs, also make sure you have PHP error reporting turned on.
contact me direct for further help.
Thanks a lot! It’s work.
If you find this script does not work then this may be due to safe mode being enabled
The script uses fsockopen();
#
stars said,
February 22, 2007 @ 11:35 pm
It does not work on my server. I downloaded the file pagerank.phps then change to pagerank.php and upload to my server and run it.But it display the blank page.Why does it happen like that?
—
You need to make a change at the bottom of the page in the last 2 lines
take away the // symbols in front of the line that has them at the beginning, save it, then retest it
hammer
1) The PageRank is displayed as a bar.If you click that bar…the browser will try to load the following page: http://www.youserver.com/www.example.com where the http://www.yourserver.com is your host server for the script…and the http://www.example.com is the page you requested for pagerank test. So the link will be http://www.yourserver.com/www.example.com if you click that bar.How can we change that into http://www.yourserver.com only ?
2) admin: can you modify that script to show the number too ? as a result.. to appear that PageRank and the number next to it.
or tell me what to modify in it.I am a PHP n00b 😛
we modified that script a little bit and here is a new version of it : http://www.rodp.net/hosted/
I don’t know if this will be the final version of it,but further updates will be available on our test site 🙂
If you insist on using my code, please at least give me credit.
lol,I use your script just for fun.I am not earning money from it.
Also, as you can see on my site,I do NOT offer your script to others,I just show you how it can be customized.
Hi, i tested the scripts with your code for this URL and did not work:
http://www.digitalwall.com/scripts/search.asp?txtKeyword=%BA%F4%B8%F4%A6%E6%BEP
Yes. It’s a Chinese language webpage and the URL was encoded to take a Chinese character. This page has page rank value 2 in Google tool bar, but it failed to pass your code.
It was the same when I tested on pagerank.gamesaga.net. Guess the algorithm cannot compute the correct PR value for this URL.
ingenious it’s really helpful.
Thank you
Thanks a lot! It’s work.
PHP-skript Google PageRank’ide lugemiseks
Google PageRank (PR) on suurus, mis näitab lehekülje tähtsust Google’i silmis kümne palli skaalal. Et DT lehekülgedel ka sellest aspektist silma peal hoida ning optimeerimise tulemusi jälgida, siis kirjutasin ühe lihtsa PHP-skripti, mis sitemap…
Good script. Thank you.
Thanks buddy… After a long research I found this page… before that I tried googlecommunity.com script ,http://www.devpapers.com/article/326 .. none of these are working .. All are giving the same old 403 error…
Thanks again.. Is it ok to use http://www.google.com/images/pos.gif image diractly from google??…
i like php code for show page rank
please help me
have fun
Yes, it’s work, i love you 🙂
You can take the PageRank tool from a web directory script and then just modify it a little ! 🙂
http://directory.ipgp.net/
Hi, I just uploaded the file on my server http://www.dezigno.com.au. it is not working. please have a look http://www.dezigno.com.au/pagerank.php. another thing, please tell me which ares in php to customized? i have knowledge in html and css, not much with php. cheers faraz
Hi, want to confirm it really work on my site perfectly. I fully agree with your decision about differ chechsum by server. Thank you for your great wotk!
Thank you!!!
¡¡ you made a really good job !!
i include it in my service, check it out: http://www.viciao2k3.net/services/xinu?lang=uk
Grettings from Spain
your script is really work, nice
other pagerank script is junk..i have tried and none of them works
It works!!! Big thanks!
i do have a question about multiple data centers, has anyone tried to get pr from different data centers by this script?
THX. It works on 64bit Linux and Mac
To NERVE,
admin: can you modify that script to show the number too ? as a result.. to appear that PageRank and the number next to it.
or tell me what to modify in it.I am a PHP n00b
ju
return $out.$out2;st look for the line
// $out=’‘.$html.’‘; from bottom 7
after that delete return $out and add following two lines and it will display number too. variable $pr hold pagerank value.
$out2=”Your PageRank is “.$pr.”/10”;
What is the final working page rank script? I tried on my server but noticed nothing but a blank page.. pls help!
Thanks!
Thank you for sharing. God bless and Godspeed.
great job, thank you very much
for all those that couldn’t make it work
DELETE THE // ON LINE 135 (the one before the last one)
Thanks!
Looked around for this Google Pagerank script for quite a while.
Finally found someone who did a good work.
Many script i tried but didn’t work on my server. But you rock!!!
Keep it up!! great job!!!
many people sell scripts for money but your giving it for free!! thumbs up!
Aww! I’ve been scouring the internet for scripts just like this. I would like to run a “php page rank checker script” WITHIN a wordpress post. To run php codes in a WordPress post, I used http://www.nosq.com/blog/runphp/ plugin.
I guess this HM2K’s script and WordPress’ runPHP script doesn’t play well together. I get an error like this:
—
Warning: fsockopen() [function.fsockopen]: php_network_getaddresses: getaddrinfo failed: Name or service not known in /home/mydeskbl/public_html/wp-content/plugins/runPHP/runPHP.php(410) : eval()’d code on line 78
Warning: fsockopen() [function.fsockopen]: unable to connect to :80 in /home/mydeskbl/public_html/wp-content/plugins/runPHP/runPHP.php(410) : eval()’d code on line 78
—
Pretty sure the fault lies in runPHP plugin. Nothing I can do about it.
Thanks for the sript
“A user named “AboutSledge” offered a working solution, which was the Pagerank Checksum Caculator Source Code for Python, for C and for PHP.”
site is down. anyone has the c code?
i’d like to have C code too
found some http://www.upsdn.net/html/2005-09/553.html but can’t 100% sure it works
Hello guys,
This script is great and working. I need some help, i’m working on a project which has website resources. I created sorts for all types, and for page rank i used website url query inside pagerank function, it works fine but the problem is we cannot sort by page rank. So, is there any solution to store pagerank values inside mysql so it would be able to sort?
help would be appreciated..
Try here:
http://web.archive.org/web/20070718095023/http://pagerank.gamesaga.net/
thank you for url but i’m a bit confused what to do with it. Newbie in mysql.. could you please guide me which one i download and how i save pr values into mysql?
thank you!
Hi Hm2k,
Thanks for this script.
It will help me to keep tack of PR of my sites.
Thanks for the script! It works great on our server, but I do have one hang up. I’d like to configure the script to automatically display the pagerank of a site I hard code into it instead of inputting a site by hand in the text box. I’ve been experimenting with no luck, has anyone done this?
Please let me know if you have any suggestions.
God dammit, you are my Hero !
Since my Hoster has changed to Debian (gaijins) old script didnt work anymore.
Took me 2 Days to find this here and WEEEEEEE …. works like a charm !
Thanks alot *excited*
Big thanks for this script!
no reply?
can’t i save page ranks in mysql?
@Raja Amer Khan:
Usually you call the funktion pagerank( ), provide an url and receive the pagerank in $pr
So, after receiving $pr Value, just store it into your database.
Only thing you should consider is, that you should think about a function for updating those values, too
in case, google does its dance and things will change.
well i’m trying something like this:
MYSQL:
Website | Title
i use pagerank(“$row[‘website’]”)
this works perfect but this cannot be sorted.
I tried to add php command in mysql but it didnt work, could you please explain what your saying?
thank yoU!!
Set up field for pagerank in your database
Then basically (this aint a code to copy paste… just a basic idea:
while (mysql_query(“select bla from bla ….. “)) {
if (!$row[`pagerank`]){ // check if PR is already set
mysql_query (“alter table xxxxxxx ……. value”.pagerank($row[`website`]).”)”; // depends on your code-style how you call the function but i am sure you can fiddle it to work
}
}
Use something like this to store pagerank for your sites.
Then you should be able to call these site in Order of their Pageranks
by useing order by
Other Way would be, that you use php sort : http://de3.php.net/manual/en/function.sort.php
Thank you so much for your suggestions.
I will surely try that code. Could you please add my email in your msn or give me your email?
Hi, i’ve try this code at my hosting server (godaddy shared hosting)
i try the url google.com but the rank is still at N/A or 0 state
http://www.online-program.net/tools/pr/pagerank.php?url=www.google.com
i have already tried many google pagerank code for this weeks and still no luck 🙁
last time i was assume maybe my server is running on linux 32 bits
i’ve also try Get google page rank (32bit and 64 bit systems)
http://www.webmasterworld.com/php/3318556.htm
but this method also fail. please help…
thank you very much