当我在facebook linter中调试我的网页时,它会一直显示警告:
“未提供''属性'og:''类型'字符串'的标题”
我已经阅读了有关SO的建议,并尝试过:
但警告是一样的。
测试页面代码是:
<!DOCTYPE html>
<html prefix="og: http://ogp.me/ns#" >
<head>
<title>testing page</title>
<meta property="og:title" content="testing page og title" />
<meta property="og:type" content="article" />
<meta property="og:url" content="https://www.skinvac.com/test.html" />
<meta property="og:image" content="https://www.skinvac.com/test-image.png" />
<meta property="og:description" content="testing page og description " />
<meta name= "keywords" content="test " />
<meta name= "description" content="test" />
</head>
<body>
<h1>test</h1>
<img src="test-image.png">
</body>
</html>
调试结果可以在这里看到facebook share debugger result
有一个警告:“'og:type'属性是必需的,但不存在。”
但是“og:title”属性位于标题标记中。
我该如何解决这个问题?
谢谢
您使用的是https,但没有有效的SSL证书。用代码中的http替换https,然后使用http链接进行测试。