Google自定义搜索和Opensearch

时间:2010-07-20 14:21:53

标签: google-search opensearch

我的网站上有一个Google自定义搜索引擎,我最近实现了opensearch XML文件,以便我可以在浏览器的搜索框中添加我们网站的搜索。

知道如何将自动填充/建议功能添加到浏览器的搜索框中吗?

1 个答案:

答案 0 :(得分:3)

我假设您已经在Google CSE搜索引擎配置上启用了“自动填充功能”。

下一步是在Url元素中添加type“{/ 1}}”application / x-suggestions + json“元素。我对此进行了一些调查,以下网址似乎应该有效(请务必输入您自己的合作伙伴OpenSearchDescription

[YOUR PARTNER ID]

如,

http://www.google.com/complete/search?q={searchTerms}&partnerid=`[YOUR PARTNER ID]`&ds=cse&output=firefox

这是a little webapp我创建的(预先填充了一些有用的值)来帮助您使用OSDD。

相关问题