RSS 或 Atoms 中的多个作者
据我所知,Atom 1.0 和 Rss 2.0 都不支持多个作者。我想要的只是与你们再次检查是否有或多或少标准的方法来包含多个作者,除了这样:
<author>Auhtor A., Author B.</author>
As far as I can see both Atom 1.0 and Rss 2.0 don't support multiple authors. What I want is just to double check with you guys whether there is a more or less standard way for including multiple authors except like so:
<author>Auhtor A., Author B.</author>
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(2)
虽然您对 RSS 的看法可能是正确的,但 Atom 1.0 确实指定了列出多个作者的格式。它看起来像这样:
<作者>
<姓名>简·多伊
<作者>
<名字>约翰·多伊
是否所有提要阅读器都处理这个问题是另一回事。例如,Safari 5 和 Google Reader 都仅显示列表中的最后一位作者。这可能是因为这些阅读器的交互模型和 UI 是根据 RSS 设计的,因此他们忽略了支持 Atom 的更高级功能。
While you may be right about RSS, Atom 1.0 does specify a format for listing multiple authors. It looks something like this:
<author>
<name>Jane Doe</name>
</author>
<author>
<name>John Doe</name>
</author>
Whether or not all feed readers handle that is a different matter. Both Safari 5 and Google Reader, for instance, display only the last author in the list. This may be because the interaction model and UI for these readers were designed with RSS in mind and so they neglect to support the more advanced features of Atom.
这是关于此的一篇很好的博客文章:
http://www .xn--8ws00zhy3a.com/blog/2007/04/rss-email-addresses
基本上答案是否定的,对于多个作者来说没有标准格式,因为甚至不是单个作者使用的标准格式。事实上,根据 RSS 2.0 标准,
标签不是用于作者姓名,而是用于作者的电子邮件地址。他们以 [email protected] (John Doe),但没有一个固定的标准说必须这样做 是。基本共识是您不能期望解析该字段。既然是这种情况,您可以以任何您想要的方式列出它,如果有人使用
标签,很可能他们只是显示它,所以您应该可以开始了。Here is a good blog post about this:
http://www.xn--8ws00zhy3a.com/blog/2007/04/rss-email-addresses
Basically the answer is no, there is no standard format for multiple authors because there isn't even a standard format used for single authors. In fact, according to the RSS 2.0 standard, the
<author>
tag isn't for the name but for the email address of the author. They specify it in the format of [email protected] (John Doe) but there is not a set standard saying that is the way it must be. The basic consensus is that you cannot expect to parse this field. Since that is the case, you can list it any way you want and if someone is using the<author>
tag, most likely they are just displaying it so you should be good to go.