Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to check the number of shares of an url on Google+?

Tags:

google-plus

Is there a way to check how many shares of url is done on Google+?

The equivalent from Facebook and Twitter would be: http://graph.facebook.com/http://stackoverflow.com and http://urls.api.twitter.com/1/urls/count.json?url=http://stackoverflow.com

Is there an equivalent on Google+?

like image 351
user1998974 Avatar asked Feb 28 '14 08:02

user1998974


1 Answers

Are you looking for this?

https://plusone.google.com/_/+1/fastbutton?url=http://stackoverflow.com

If you are searching for the text value, you can search the following line in the source code of the url:

<div id="aggregateCount" class="Oy">{NUMBER_OF_SHARES}</div>

The following JavaScript will extract the number of shares from the url:

parseInt(document.getElementById('aggregateCount').innerHTML.replace('.',''))
like image 86
ReeCube Avatar answered Dec 25 '22 10:12

ReeCube