所以,我有下面的代码,当输入谷歌的 Rich Snippet Testing Tool时它可以正常工作。问题是我不需要Venue Name
链接到任何网址。但是,当我取出a
标记并将该行简化为 just<span itemprop="name">Venue Name</span>
时,测试工具告诉我该页面不包含任何丰富的片段标记。此外,它会发出如下警告:
Warning: Event urls are pointing to a different domain than the base url.
有没有办法不将场地名称与任何东西联系起来?
基本上,我只希望结果看起来像这样(只有“买票”部分链接):
2 月 2 日 - 亚利桑那州凤凰城 - Crescent Ballroom -购买门票
我已经上传了我正在测试的 html 文件,并在此处输入了测试工具。
<div itemscope itemtype="http://schema.org/MusicGroup">
<h1 itemprop="name">Name</h1>
<div itemprop="events" itemscope itemtype="http://schema.org/Event">
<meta itemprop="startDate" content="2012-02-02">Date —
<span itemprop="location">City, State</span> -
<a href="/tour" itemprop="url">
<span itemprop="name">Venue Name</span>
</a> -
<a href="http://ticketlink.com" itemprop="offers">Buy tickets</a>
</div>
</div>
2/16 - 更新代码
<div itemscope itemtype="http://schema.org/MusicEvent">
<h1 itemprop="name">Name</h1>
<div itemprop="events" itemscope itemtype="http://schema.org/Event">
<meta itemprop="startDate" content="2012-02-02">Date —
<span itemprop="location" itemscope itemtype="http://schema.org/Place">
<span itemprop="address" itemscope itemtype="http://schema.org/PostalAddress">
<span itemprop="addressLocality">City</span>,
<span itemprop="addressRegion">State</span>
</span>-
<span itemprop="name">Venue Name</span> -
<div itemprop="offers" itemscope itemtype="http://schema.org/Offer">
<a href="http://ticketlink.com" itemprop="url">Buy tickets</a>
</div>
</span>
</div>
</div>
2/17 - 更新代码
<div itemscope itemtype="http://schema.org/MusicGroup">
<h1 itemprop="name">Name</h1>
<div itemprop="events" itemscope itemtype="http://schema.org/MusicEvent">
<meta itemprop="startDate" content="2012-02-02">Date —
<span itemprop="location" itemscope itemtype="http://schema.org/Place">
<span itemprop="address" itemscope itemtype="http://schema.org/PostalAddress">
<span itemprop="addressLocality">City</span>,
<span itemprop="addressRegion">State</span>
</span>-
<span itemprop="name">Venue Name</span> -
<div itemprop="offers" itemscope itemtype="http://schema.org/Offer">
<a href="http://ticketlink.com" itemprop="url">Buy tickets</a>
</div>
</span>
</div>
</div>
2/17 - 新更新的代码
<div itemscope itemtype="http://schema.org/MusicGroup">
<h1 itemprop="name">Name</h1>
<div itemprop="events" itemscope itemtype="http://schema.org/MusicEvent">
<meta itemprop="startDate" content="2012-02-02">Date —
<span itemprop="location" itemscope itemtype="http://schema.org/Place">
<span itemprop="address" itemscope itemtype="http://schema.org/PostalAddress">
<span itemprop="addressLocality">City</span>,
<span itemprop="addressRegion">State</span>
</span>-
<span itemprop="name">Venue Name</span> -
</span>
<div itemprop="offers">
<a href="http://ticketlink.com" itemprop="url">Buy tickets</a>
</div>
</div>
</div>