Feeds are very handy. It is possible to subscribe to different kind of news and information. Unfortunately even today, often people don't use them for some inexplicable reasons. Thirty years ago you had to buy and read a newspaper to get to know the 'News'. Fifteen years ago you opened your browser and visited one website after another to get to know the "News". Today, you can still do both but it's also possible to use a feed aggregator. Google's reader and the dynamic bookmark toolbar of your browser (e.g. Firefox) are quite popular. The Joomla! 1.6 Newsfeeds component is an aggregator as well. Not as sophisticated like Google's reader, but also quite useful.
The news feed component allows you to collect feeds from other sites and publish it on your site.
In today's world of social media everyone probably has dozens of user accounts. Often videos and images are stored on youtube.com and flickr.com. In a company, the situation is even more complex. Imagine how much information is available as newsfeeds about a project like Joomla! or about your company.
A feed reader on our website
In the next example, we want to build a feed reader on our website. I'll try to collect all the bits and pieces which are created around our company and list them in a table. We have a vimeo account for our videos, a flickr account for images, several twitter accounts and that's still not all :-)
First, I create a newsfeeds category called cocoate in Components → Newsfeeds → Categories and afterwards for every feed an entry in Components → Newsfeeds → Feeds (Figure 1). The single problem is often finding the correct feedlink. For example, our vimeo video feed link looks like this: http://vimeo.com/cocoate/videos/rss. The Flickr feed link of our photos looks more complicated (http://api.flickr.com/services/feeds/photos_public.gne?id=17963290@N00&lang=en-us&format=rss_200).
In the publishing options you have to enter how many feed entries you want to show and the number of seconds before the cache is refreshed. Joomla! only stores the amount of items which you configured in its cache. This is an important detail because in some countries it is not allowed to store the content from a public newsfeed in your database.
Figure 1: A collection of newfeeds
Finally, you have to create a menu item in a menu of your choice. The Newsfeeds component comes with three different layouts:
- List of all News Feed Categories
- List of News Feed in a Category
- Just a Single Newsfeed
I chose the second one because I have all my feeds in one category. On the website, Joomla! aggregates my feeds, e.g. the Vimeo video feed (Figure 2)
Figure 2: News feed data
When you create a news feed, you can configure in Display Options among other things whether you want to display the feeds image or not. Also, you can limit the number of characters of the content which should be displayed. This feature is very useful if the feed contains longer articles or if you use the Feed Display module. You can create one in Extensions - Modules - New. Here is e.g. the New York Times feed (http://feeds.nytimes.com/nyt/rss/HomePage). Configure the module at position-4 and configure the Basic Options (Figure 3).
Figure 3: News feed module
The result on the webpage will look like in Figure 4.
Figure 4: News feed module on website