我已經取得了一些進展,讓Facebook分享一些添加grom我的網站,從MySQL數據庫動態生成。我可以在我的網站的主頁上插入一個Iframe。爲什麼dosn't facebook喜歡這個代碼?
<iframe src="//www.facebook.com/plugins/like.php? href=http://www.webaddress.com.au/description.php%3Fid%3D'.$id.'&width&layout=standard&action=like&show_faces=true&share=true&height=80&appId=596610807121620" scrolling="no" frameborder="0" style="border:none; overflow:hidden; height:80px;" allowTransparency="true"></iframe>
然後在頁面上此鏈接,我有以下的元標記。
<meta property="og:title" content="Listed in the Two Year Olds section" /> <meta property="og:url" content="<?php echo $_SERVER['PHP_SELF'];?>" /> <meta property="og:description" content="<?php echo $row['horsename'];?> " />
是否有這樣做的更Facebook的方式間友好?由於它有時似乎有效,但並非總是有效?
感謝
哪部分不工作?網址內容? – Ghost 2014-10-09 00:39:14
你的URL有一個空格字符,你可能會有一個更好的時間與urlencode()的使用 – Scuzzy 2014-10-09 00:40:50
Wehn我在Facebook調試它不像URL – user2432677 2014-10-09 00:42:52