0

I have a web site that displays a table of contents, and I'd like to use the Google Plus One button as a kind of persistent "favourite" marker. So a user would Plus One a page, and then in my table of contents I would show that page as being "Plus Oned" somehow (either bold the entry, show a plus image or something similar).

So is there any way to call the Plus One api to find out if a URL has been "Plus Oned" by the current user?

Note that I don't want to get the plus one count (as shown at http://www.tomanthony.co.uk/blog/google_plus_one_button_seo_count_api/) and I don't want to have to manually intercept plus one clicks and store the details myself.

http://www.tomanthony.co.uk/blog/google_plus_one_button_seo_count_api/ may do what I want. The isSetByViewer parameter that is returned is possibly what I want, but simply calling the web service as described in the web page always returns a isSetByViewer value of false. I would assume that some other undocumented data or cookie/header information would have to be sent to the web service identify the current user.

4

1 回答 1

0

隐藏 API 中有一个pos.plusones.getSignupState,您可以尝试用它来代替pos.plusones.get. 除此之外,我认为您应该在 userID 参数中指定 G+ 用户 ID。

此外,您可以尝试使用 wireshark、webkit 检查器和 chrome://net-internals 嗅探 +1 按钮的网络流量(观察到 client6.google.com 的 SPDY 流量)。或者,您可以尝试使用 step 调试 js 代码以查找使 +1 按钮突出显示的变量。

于 2012-04-26T23:22:45.333 回答