我想添加一個Facebook的像按鈕到一個網站,但它從來沒有出現。Facebook的按鈕不顯示
下面是從我的網頁上的相關細節:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
xmlns:fb="http://www.facebook.com/2008/fbml"
xmlns:og="http://opengraphprotocol.org/schema/" dir="ltr" lang="en" xml:lang="en">
<head id="Head1" runat="server">
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8"/>
<meta property="og:title" content="[____].com" />
<meta property="og:type" content="blog" />
<meta property="og:url" content="http://www.[____].com/" />
<meta property="og:image" content="http://[____].gif" />
<meta property="og:site_name" content="[____].com" />
<meta property="fb:app_id" content="[____]" />
<link rel="stylesheet" type="text/css" href="http://fonts.googleapis.com/css?family=News+Cycle" />
<link rel="Stylesheet" type="text/css" href="../../Content/css/[____].min.css" media="screen, projection" />
</head>
<body>
<div id="fb-root"></div>
<script>
window.fbAsyncInit = function() {
FB.init({
appId: '[____]',
status: true,
cookie: true,
xfbml: true
});
FB.XFBML.parse(); **- 1**
};
FB.XFBML.parse(); **- 2**
(function() {
var e = document.createElement('script');
e.type = 'text/javascript';
e.src = document.location.protocol + '//connect.facebook.net/en_US/all.js#xfbml=1';
e.async = true;
document.getElementById('fb-root').appendChild(e);
}());
</script>
Like button goes here:<fb:like></fb:like>
...
</body>
</html>
的問題是很簡單,雖然腳本執行負載,從來沒有出現像按鈕。我也通過Facebook Linter運行它,它不會突出任何問題。
任何想法?
有趣的是,你剛剛解決了我自己的挖掘時間。 –