开发者

How to find the google page rank of a website in php?

How开发者_Go百科 to find the google page rank of a website in php?


I googled and found a few classes:

  • http://www.pagerankcode.com/download-script.html
  • http://www.fusionswift.com/examples/2011/10/google-pagerank-api-in-php-october-2011/
  • http://www.phpclasses.org/package/2682-PHP-Retrieve-the-Google-page-rank-of-a-given-URL.html

Quickly looking, I think the second one is your best bet (it uses the Google Toolbar API). Just make sure your server supports CURL


There's a PHP script at http://www.brightyoursite.com/blog/2010/06/01/use-php-to-get-google-page-rank/ which works pretty well for this. It makes requests to the Toolbar API.

Usage is pretty simple:

include "pr.php";
$url='http://www.example.com';
echo "$url  PR is ". getPagerank($url) ;
0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜