Linkedin在分享时显示3个不同的图像 [英] Linkedin show 3 different image when sharing
问题描述
Linkedin尝试分享时显示不同的3张图片。这是头标签
Linkedin show different 3 image when trying to share. Here is then head tags
<meta property="og:site_name" content="OkyTalk">
<meta property="og:title" content="OkyTalk ">
<meta property="og:type" content="website">
<meta property="og:url" content="https://okytalk.com/teachers/profile/displayProffesional">
<meta property="og:image" content="https://okytalk.com/media/okytalk/img/share.jpg">
<meta property="og:image:type" content="image/jpeg">
<meta property="og:image:width" content="470">
<meta property="og:image:height" content="246">
任何想法如何只显示一个?其他分享(脸书,推特,谷歌+)工作正常。
Any Ideas how to show only one ? Others share(facebook, twitter, google+) works fine.
推荐答案
由于某种原因,LinkedIn正在接收img标签中的图片与Facebook等不同。
LinkedIn are picking up the images in the img tag for some reason unlike Facebook etc.
解决方法是更改您共享的页面上的img标签中的图像以设置CSS中的图像并将img标签更改为div 。
The workaround is to change the images in the img tags on the page you are sharing to set the images in CSS and change to img tag to a div.
添加如下样式:
#howitworksstudent{
background: url(https://okytalk.com/media/okytalk/img/how-it-works-student.png);
width: 100%;
height: 100%;
background-repeat: no-repeat;
}
并将你的img标签更改为:
and change your img tag to:
<div id="howitworksstudent"/>
不理想,但可以解决问题。我已经对此进行了测试,并且能够重新创建您的初始问题,因此我知道它有效。
Not ideal but gets you around the problem. I have tested this and was able to recreate your initial issue so I know it works.
希望有所帮助。
这篇关于Linkedin在分享时显示3个不同的图像的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!