Read the statement by Michael Teeuw here.
Newsfeed "ignoreOldItems" does not work
-
Hi,
my config says to ignore items older than 14 hours (50400000ms),
but that does not work. I still see news older than this.Heres my newsfeed module:
{ module: "newsfeed", position: "bottom_bar", showSourceTitle: true, showPublishDate: true, config: { feeds: [ { title: "Kurier", url: "http://kurier.at/xml/rssd" }, { title: "Der Standard", url: "http://derStandard.at/?page=rss&ressort=Seite1" }, { title: "Giga", url: "http://www.giga.de/feed/" } ], ignoreOldItems: "true", ignoreOlderThan: 50400000, updateInterval: 20000 } }
-
@StrikeBack83 I just checked your config and it seems to work fine, as the oldest news I got was 12.5 hours old.
Though there are some small issues with your config:
... position: "bottom_bar", showSourceTitle: true, showPublishDate: true, config: { feeds: [ ...
showSourceTitle
andshowPublishDate
are config options and have to be moved into the config section like... position: "bottom_bar", config: { showSourceTitle: true, showPublishDate: true, feeds: [ ...
But why did they work then?
Because their default value is set totrue
so you don’t have to specify it at all like... position: "bottom_bar", config: { feeds: [ ...
Another issue is
ignoreOldItems
. A boolean (true
andfalse
) have to be defined without quotes, otherwise it will be always true."true" => true
and"false" => true
], ignoreOldItems: true, ignoreOlderThan: 50400000,
-
Hi,
IfshowSourceTitle: true, showPublishDate: true,
is true by default i’m going to delete it completely.
I’ll try the “ignoreOldItems: true” without quote marks when i get home!
Thanks!Edit: Seems like it’s working at the moment. Obviously it was the “true” in quots.