RSS feed:如何建议更新间隔? [英] RSS feed: how to recommend an update interval?

查看:128
本文介绍了RSS feed:如何建议更新间隔?的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

发布RSS feed时,XML中是否有一些属性可以用来建议更新间隔/频率?

When publishing an RSS feed, is there some attribute in the XML that can be used to recommend the update interval/frequency?

如果它不是标准的一部分,是否有一些公认的方法?

And if its not part of the standard, is there some generally recognised way?

推荐答案

此处的规范 http://www.rssboard.org/rss-specification#requiredChannelElements 为频道元素指定了以下可选参数:

The specification here http://www.rssboard.org/rss-specification#requiredChannelElements has these optional parameters specified for the channel element:

这些可以告诉客户何时不需要更新..

These to tell clients when they don't need to update..

skipHours-聚集者的提示,告诉他们可以跳过哪些时间.该元素最多包含24个<小时>子元素的值是介于0到23之间的数字,代表GMT中的时间,如果聚合器支持该功能,则它们可能无法在< skipHours>元素.从午夜开始的小时为零.

skipHours - A hint for aggregators telling them which hours they can skip. This element contains up to 24 < hour > sub-elements whose value is a number between 0 and 23, representing a time in GMT, when aggregators, if they support the feature, may not read the channel on hours listed in the < skipHours > element. The hour beginning at midnight is hour zero.

skipDays-聚集者的提示,告诉他们可以跳过哪些天.该元素最多包含七个<日>子元素,其值为星期一,星期二,星期三,星期四,星期五,星期六或星期日.在< skipDays>元素.

skipDays - A hint for aggregators telling them which days they can skip. This element contains up to seven < day > sub-elements whose value is Monday, Tuesday, Wednesday, Thursday, Friday, Saturday or Sunday. Aggregators may not read the channel during days listed in the < skipDays > element.

和/或此功能可告知客户他们需要多长时间更新一次.

and/or this for telling clients how often they need to update.

ttl-ttl表示生存时间.这是分钟数,指示从源刷新之前可以将频道缓存多长时间.

ttl - ttl stands for time to live. It's a number of minutes that indicates how long a channel can be cached before refreshing from the source.

这篇关于RSS feed:如何建议更新间隔?的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆