Php Facebook wordpress网站共享错误的图像

Php Facebook wordpress网站共享错误的图像,php,wordpress,facebook,Php,Wordpress,Facebook,我对wordpress网站和facebook共享有问题。我的网站没有任何共享按钮,我说的共享是当任何用户在facebook上粘贴url时,出现的图像是一些随机图像,而不是我想要出现的徽标 到目前为止,我所尝试的: <meta property="og:url" content="http://example.com"> <meta property="og:title" content="example name"> <meta property="og:site_

我对wordpress网站和facebook共享有问题。我的网站没有任何共享按钮,我说的共享是当任何用户在facebook上粘贴url时,出现的图像是一些随机图像,而不是我想要出现的徽标

到目前为止,我所尝试的:

<meta property="og:url" content="http://example.com">
<meta property="og:title" content="example name">
<meta property="og:site_name" content="example name">
<meta property="og:image" content="http://example.com/wp-content/uploads/2014/03/logo_example.png">
<meta property="og:image:type" content="image/png">
<meta property="og:image:width" content="105">
<meta property="og:image:height" content="72">
<link rel="image_src" type="image/png" href="http://example.com/wp-content/uploads/2014/03/logo_example.png" />

此代码是一个示例,指向图像的链接无效。

我的解决方案:


在这个网站上:我可以调试facebook元标记,发现我的图像必须至少是200x200px。因为事实并非如此,facebook总是通过其他图片来建立共享。因此,我不得不更改我的图像,并删除了宽度和高度元标记。

你有没有看过WordPress插件,可以为你自动将所有这些打开的图形数据添加到每个页面?我以前用过很多成功的方法。OpenGraph也被LinkedIn和其他一些网站使用。此插件允许您指定每篇文章/每页的图像和文本,或指定站点范围的默认值