xml – RSS feed:如何推荐更新间隔?

前端之家收集整理的这篇文章主要介绍了xml – RSS feed:如何推荐更新间隔?前端之家小编觉得挺不错的,现在分享给大家,也给大家做个参考。
发布RSS源时,XML中是否有一些属性可用于推荐更新间隔/频率?

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

此处的规范 http://www.rssboard.org/rss-specification#requiredChannelElements具有为channel元素指定的这些可选参数:

这些告诉客户什么时候不需要更新..

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 – 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.

和/或这告诉客户他们需要更新的频率.

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.

原文链接:https://www.f2er.com/xml/293094.html

猜你在找的XML相关文章