我想顯示使用URL重定向共享對話框如下所述:https://developers.facebook.com/docs/sharing/reference/share-dialogFacebook共享對話與URL重定向不工作
我試圖實現同樣使用自定義頁面我創建(與OG meta標籤),這裏是代碼:
<!DOCTYPE html>
<html>
<head>
<title>Test</title>
<meta name="description" content="Page description. No longer than 155 characters." />
<!-- Twitter Card data -->
<meta name="twitter:card" value="summary">
<!-- Open Graph data -->
<meta property="fb:app_id" content="762471050442760" />
<meta property="og:site_name" content="Facebook Developers" />
<meta property="og:title" content="Documentation for building software with Facebook - APIs, SDKs and Services" />
<meta property="og:type" content="article" />
<meta property="og:url" content="https://developers.facebook.com/docs/" />
<meta property="og:image" content="https://fbstatic-a.akamaihd.net/rsrc.php/v2/y6/r/YQEGe6GxI_M.png" />
<meta property="og:locale" content="en_US" />
<meta property="og:description" content="Learn how to integrate with Facebook's APIs and developer tools to drive growth and engagement to your app, website or content." />
</head>
<body>
</body>
</html>
該頁儲存在這個位置(這裏假的位置) - > www.mysite.com/test.html
現在我嘗試使用以下鏈接共享:https://www.facebook.com/dialog/share?app_id=MY_APP_ID&display=popup&href=www.mysite.com/test.html&redirect_uri=www.mysite.com
但是我沒有得到與他們提供的示例相同的結果。相反,我從另一個網站上獲得一些圖片和描述(根本不是我用meta標籤創建的圖片和描述)。
我該如何解決並自定義我的共享對話框?
謝謝
您在說您的og:url是https://developers.facebook.com/docs/。改用你的網址,它會更好 – WizKid