问题描述
我正在使用addthis在社交网站中共享.我正在尝试在FB上共享标题,描述等.它正在运行,但没有我的标题和描述.
I am using addthis for sharing in social networking site. I am trying to share title, description etc. on FB. It is working but not getting my title and description.
我正在使用Open Graph Debugger工具,它表示
I am using an Open Graph Debugger tool, it says that
当我单击抓取的URL确切地看到我们的抓取器为您的URL 它不显示任何内容.那是什么问题呢?
when i click on Scraped URL See exactly what our scraper sees for your URLit display none.so what is the problem?
代码:
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml"
xmlns:og="http://ogp.me/ns#"
xmlns:fb="http://www.facebook.com/2008/fbml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=UTF-8" />
<meta property="og:title" content="APPOITMENT" />
<meta property="og:type" content="article" />
<meta property="og:url" content="http://xxxxxxxx/client/appointment/index" />
<meta property="og:site_name" content="CBD"/>
<meta property="og:description" content="Workday, a provider of cloud-" />
我已经进行了一些调试.我使用codeigniter框架,并使用 .htaccess
文件进行重定向.当我在核心php文件中使用相同的代码时,它正在工作.但是在codeigniter中它不起作用.
I have done some debugging. I use codeigniter framework and i use .htaccess
file for redirecting purpose. when i use same code in core php file, then it is working. but in codeigniter it is not working.
.htaccss:
RewriteEngine on
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule .* index.php/$0 [PT,L]
CI似乎使用了类似controller/function/之类的URL.所以我认为这是FB无法简化页面的原因.所以我需要创建一个包含meta标签的单个php文件吗?
It seems that CI use URL like controller/function/. so i think this is the reason FB not able to scarp page. so do i need to create single php file that contains meta tag?
推荐答案
尝试调试您的根URL. https://developers.facebook.com/tools/debug/
Try to debug your root URL.https://developers.facebook.com/tools/debug/
这也将迫使Facebook更新您的元详细信息.
This will also force Facebook to update your meta details.
这篇关于Facebook没有获得元标记,也无法抓取网址的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持!