适用于 iPhone 应用程序的 Google Rich Snippets 无法正常工作
我已在我的网站上为我的 iPhone 应用 yycParking 设置了 Google 丰富网页摘要的代码。相关的 HTML 如下所示:
<div itemscope itemtype="http://schema.org/SoftwareApplication">
<!-- ... -->
<h2 class="txt-align-center" itemprop="description">
<strong>yycParking</strong> provides real time updates of parking in downtown Calgary
</h2>
<!-- ... -->
<div class="two-column last">
<!-- ... -->
<p>We created <strong itemprop="name">yycParking</strong> to enhance a service provided by ...</p>
<!-- ... -->
</div>
<div class="two-column last txt-align-right">
<!-- ... -->
<a title="Download the YYC Parking App from the iTunes store now" href="http://itunes.apple.com/ca/app/yycparking/id460852653?mt=8" target="_blank" itemprop="url">
<img class="alignnone size-full wp-image-436" title="app-store-badge" src="http://randomtype.ca/cms/assets/app-store-badge.png" alt="" />
</a>
<!-- ... -->
</div>
<p>
<meta itemprop="image" content="http://randomtype.ca/cms/assets/app-icon-124x124.png" />
</p>
</div>
您将从上面的 HTML 中看到我包含以下元素:
- 架构:
itemscope itemtype="http://schema.org/SoftwareApplication"
- 描述:<代码>itemprop="description"
- 名称:
itemprop="name"
- URL:
itemprop="url"
- 图片:
itemprop="image"< /code>
从阅读 丰富网页摘要软件应用程序规范 我相信我已达到 4所需的项目,并正确识别了我正在遵循的模式。
通过 Rich Snippet 测试工具 我得到的结果没有将该代码段识别为 iPhone 应用程序,并跳过了漂亮的图像,例如“剪切绳子”得到。
我错过了什么吗?我想主宰卡尔加里停车市场 - 但谷歌阻碍了我!1 :P
I've setup the code for Google's Rich Snippets for my iPhone app yycParking on my website. The relevant HTML looks like this:
<div itemscope itemtype="http://schema.org/SoftwareApplication">
<!-- ... -->
<h2 class="txt-align-center" itemprop="description">
<strong>yycParking</strong> provides real time updates of parking in downtown Calgary
</h2>
<!-- ... -->
<div class="two-column last">
<!-- ... -->
<p>We created <strong itemprop="name">yycParking</strong> to enhance a service provided by ...</p>
<!-- ... -->
</div>
<div class="two-column last txt-align-right">
<!-- ... -->
<a title="Download the YYC Parking App from the iTunes store now" href="http://itunes.apple.com/ca/app/yycparking/id460852653?mt=8" target="_blank" itemprop="url">
<img class="alignnone size-full wp-image-436" title="app-store-badge" src="http://randomtype.ca/cms/assets/app-store-badge.png" alt="" />
</a>
<!-- ... -->
</div>
<p>
<meta itemprop="image" content="http://randomtype.ca/cms/assets/app-icon-124x124.png" />
</p>
</div>
You'll see from the above HTML that I've included the following elements:
- Schema:
itemscope itemtype="http://schema.org/SoftwareApplication"
- Description:
itemprop="description"
- Name:
itemprop="name"
- URL:
itemprop="url"
- Image:
itemprop="image"
From reading the rich snippet software application specs I believe I've hit the 4 required items, and properly identified the schema I'm following.
Running it through the Rich Snippet testing tool I get a result that doesn't identify the snippet as an iPhone app, and skips out the nice image like "Cut the Rope" gets.
Am I missing something? I want to dominate the Calgary parking market - but Google is holding me back!1 :P
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
看起来,您缺少价格和平均评分。
我不知道是否有严格的定义需要什么和不需要什么,但添加这两个解决了我的问题。
您可能还需要考虑添加更多信息,例如操作系统和版本。
您可以在此处查看工作示例。
PS:我不是这个主题的专家,我只是编辑了“割绳子”页面并不断测试,直到代码最少但仍然有效。 :P
As it seems, you're missing a price and an average rating.
I have no clue if there's a strict definition of what's required and what's not, but adding these two solved the problem for me.
You might also want to consider adding some more information, such as OS and version.
You can see a working example here.
PS: I'm not an expert on this topic, I just edited the Cut the Rope page and kept testing until the code was minimal but it still worked. :P
实际的“错误”似乎是测试工具的错误。但是,我查看了您提到的“割绳子”示例,实际上拉动图像和其他格式的是 开放图协议:
The actual "error" seems to be an bug with the Testing Tool. But, I looked at the "Cut the rope" example you mentioned and what's actually pulling the image and other formats is the Open Graph protocol: