Integrating feedfeeder
This How-to applies to: 1.5, 1.6
- Download feedfeeder.
- Add FeedfeederFolder to the 'allowed content types' of sdotNewsFolder (in the ZMI in portal_types).
- Add Image to the 'allowed content types' of FeedfeederFolder (in the ZMI in portal_types).
- In 'Site Setup' goto 'sdotNews configuration' and add 'FeedFeederItem' to the 'Types listed in News'.
- Add a 'sdotNews folder' to your site.
- Inside the Newsfolder add a FeedfeederFolder.
- If you want the items to display a newscategory icon add an image with the id sdot_folder_icon.
If you import the feeds for the first time you may see that the imported Items are all displayed at the date you first imported them - so if you want to import lots of 'legacy' information you might just set the 'effective' date to the feeds last updated date with this simple python script:
# set the items effective date to the rss dateName this script feedfolder-set-effective and append the name to your Feedfolder url.
request = container.REQUEST
RESPONSE = request.RESPONSE
# Return a the dates to which the feeditems are set
feeditems = container.portal_catalog(portal_type = 'FeedFeederItem' ,path='/'.join(container.getPhysicalPath()));
for feeditem in feeditems:
item = feeditem.getObject()
print item.feedItemUpdated
item.setEffectiveDate (item.feedItemUpdated)
print item.EffectiveDate()
return printed
Example: http://www.iwlearn.net/News
see also:
-
Feedfeeder
- A product which pulls down remote syndicated feed items. Those items can be easily integrated into sdotNews (see howto section)