When i publish new posts, i notice the new posts do not appear in the feed http://mysite.com/feed
instantaneously, there is always lag time, one or several hours.
When i change something in wp-includes/feed-rss2.php
file (just echo 'test'
), it also takes one or 2 hour to see the test
word in http://mysite.com/feed
, it means wordpress only use that file periodically.
Anyone know how to solve this problem? I want whenever the http://mysite.com/feed
page is open in browser, it must use wp-includes/feed-rss2.php
file.
Thanks!
Just like the pages WordPress makes normally, feeds are generated on-demand, they’re not “rebuilt” or “updated” or any sort of thing like that. So posts will appear in the feed at the exact instant that they are published.
If you’re seeing a lag time, then you may be using a caching plugin, such as WP-Super-Cache, or some form of feed redistribution service, such as FeedBurner, which is holding a copy of the feed for some period of time and only refreshing from the actual feed periodically.
In this case, you need to either configure the caching plugin to not cache the feed, or stop using the feedburner-like service.