Facebook我喜欢按钮不能一直工作 [英] Facebook I like button not working all the time

查看:116
本文介绍了Facebook我喜欢按钮不能一直工作的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我使用以下代码来实现相似按钮:

I have used the following code to implement the like - button:

标题

<!-- Facebook Metatags -->
<meta property="og:image" content="http://mysite/logo.gif"/>
<meta property="og:locality" content="mycity"/>
<meta property="og:country-name" content="Germany"/>
<meta property="og:latitude" content="52.xxxxxxx"/>
<meta property="og:longitude" content="9.xxxxxxx"/>
<meta property="og:type" content="product"/>
<meta property="og:site_name" content="mypage.com"/>
<meta property="og:url" content="http://mypage.de/myproduct/myproductkey"/>
<meta property="og:title" content="Myproduct Description"/>

Body on mypage.de/myproduct/myproductkey

<div id="facebook-likebox">
<script src="http://connect.facebook.net/de_DE/all.js#xfbml=1"></script>
<fb:like href="http://mypage.de/myproduct/myproductkey" width="450" height="90" show_faces="false"></fb:like>
</div>

结果不一致:大多数情况下,它有效,但有时我会收到此错误: p>

The result is inconsistent: Most of the time it works, but sometimes I get this error:


您未能提供
管理员的有效列表。您需要使用
\fb:app_id \\元标记或使用
\fb:admins\元标记来指定
管理员
以逗号分隔的Facebook
用户列表。

You failed to provide a valid list of administators. You need to supply the administors using either a \"fb:app_id\" meta tag, or using a \"fb:admins\" meta tag to specify a comma-delimited list of Facebook users.

此错误没有任何意义,因为当我调用页面后来还是别人叫它再次工作的页面。任何想法这里有什么问题。

This error makes no sense because when I call the page later or somebody else calls the page it works again. Any idea what is wrong here.

编辑

这些元标记

<meta property="fb:admins" content="xxx"/>
<meta property="fb:app_id" content="xxx"/>

我重新检查了 https://graph.facebook.com/xxx

但是我仍然有时会收到错误。新的错误是:

But I still get get errors sometimes. The new error is:


fb:app_id元标记中指定的
的应用程序IDxxx为
无效。

The app ID "xxx" specified within the "fb:app_id" meta tag was invalid.

但大多数时间everyrthing的作品。有没有人知道如何解决这个问题?

But most of the time everyrthing works. Does anybody have any idea on how to solve this issue?

编辑1

我们的网站使用负载平衡器,并有很多外部脚本(E-Tracker和其他跟踪解决方案)

Our site uses a load balancer and has a lot of external scripts (E-Tracker and other tracking solutions)

编辑2

我们使用LINT https://developers.facebook。 com / tools / lint / 来检查页面

We used LINT https://developers.facebook.com/tools/lint/ to check the page

它有时会出现错误(无效的app_id),有时返回为有效。但是,元标记的应用程序被正确地解析,这是有效的应用程序。

It gives sometime an error (invalid app_id )and sometimes returns as valid. But the app-id from the meta-tags is allways parsed correctly and it is the valid app-id.

推荐答案

出现不一致行为的原因是负载均衡器。我们停用了负载平衡,LINT总是显示一致的结果。

It turns out that the reason for the inconsistent behaviour was the loadbalancer. We deactivated loadbalancing and LINT always showed consistent results.

我不知道负载平衡改变了什么。元标签是相似的。

I have no idea what the Load balancing changed. The meta-tags are similar.

我使用了管理员 - 元标记。我没有使用app-id标签。这是在规范中写的。

I used the admins- metatag. I did not have to use the app-id tag. Thats how it is written in the specification.

这篇关于Facebook我喜欢按钮不能一直工作的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆