Facebook OG标签不工作 [英] Facebook OG tags Not Working

查看:113
本文介绍了Facebook OG标签不工作的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我有一个简单的rails 3应用程序与FB像按钮。 Ive使用FB OG标签来获取图像在类似事务中发布的其他相关信息。



当我在本地服务器上测试并且上传后,谎言以Facebook的默认映像发布,不包含OG标签中的其他信息。



我查看了其他几个问题,回顾了FB的开发人员关于如何使用OG标签的说明,我确定我已经正确输入了。想知道是否有另一个步骤或其他我失踪的东西



我的头部分中的标签如下所示

 <!DOCTYPE html> 
< html>
< head>
< meta name =viewportcontent =width = device-width,initial-scale = 1.0>
< title>我的标题< / title>
< meta property =og:titlecontent =我的网站/>
< meta property =og:site_namecontent =我的网站/>
< meta property =og:urlcontent =http://www.mysite.com//>
< meta property =og:imagecontent =http://www.mysite.com/assets/image.png/>
< meta property =og:typecontent =ecommerce/>
<%= stylesheet_link_tagapplication,:media => all%>
<%= favicon_link_tag/favicon.ico%>
<%= csrf_meta_tags%>



正文东西

解决方案

查看此链接: http://developers.facebook .com / tools / debug



在此处输入您的网址或 og 标签,以获取标记有问题。


I have a simple rails 3 app with a FB like button. Ive used FB OG tags to get the image other pertinent info posted during the like transaction.

when i test on my local server and after uploading, lies are posted with Facebook's default image and doesn't include other info from the OG tags.

I looked at few of the other questions on this, reviewed FB's developer instructions on how to use the OG tags and i'm certain I've entered them correctly. Wondering if there's another step or something else that i'm missing

I have the tags in my head section like so

<!DOCTYPE html>
<html>
<head>
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>my title</title>
<meta property="og:title" content="My Site" />
<meta property="og:site_name" content="My Site" />
<meta property="og:url" content="http://www.mysite.com/"/>
<meta property="og:image" content="http://www.mysite.com/assets/image.png"/>
<meta property="og:type" content="ecommerce"/>
<%= stylesheet_link_tag "application", :media => "all" %>
<%= favicon_link_tag "/favicon.ico" %>
<%= csrf_meta_tags %>

body stuff

解决方案

Check out this link: http://developers.facebook.com/tools/debug

Input your url or og tag here to get if there is something wrong with your markup.

这篇关于Facebook OG标签不工作的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆