gpt4 book ai didi

seo - 错误 : Page contains property "query-input" which is not part of the schema

转载 作者:塔克拉玛干 更新时间:2023-11-03 02:30:36 27 4
gpt4 key购买 nike

我从 Google RichSnippets testing tool 得到这个错误:

Error: Page contains property "query-input" which is not part of the schema.

但是我哪里弄错了?

HTML:

<div id="dkAjaxSearch">
<input id="ajaxSearch" type="text" value="" name="search_term" itemprop="query-input">
Press Enter to search
</div>

JSON-LD:

<script type="application/ld+json">
{
"@context": "http://schema.org",
"@type": "WebSite",
"url": "https://domain.com/",
"potentialAction": {
"@type": "SearchAction",
"target": "http://domain.com/search/{search_term_string}",
"query-input": "required name=search_term_string"
}
}
</script>

文档:An improved search box within the search results

最佳答案

documentation about Actions 中有解释:

Additional information is often required from a user or client in order to formulate a complete request. To facilitate this process we need the ability to describe within a potential action how to construct these inputs. Since we need this capability for filling in any property of an Action, we introduce a notion of property annotations using a hypen ("-") delimiter. For example, by specifying a "location-input" property on a potential action we are indicating that "location" is a supported input for completing the action.

但由于此属性不存在(即,它未在 SearchAction 的属性表中定义),验证器将其报告为错误。

此问题已在 Schema.org 的 GitHub 上进行了讨论:SearchAction example uses "query-input" property that is not defined

所以你没有做错什么。除非 Schema.org 决定应以不同的方式处理操作,否则验证器可能应该更新并允许 -input-output 后缀。

关于seo - 错误 : Page contains property "query-input" which is not part of the schema,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/27140153/

27 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com