rss

Importing Content Using The Feeds Module

This lesson shows how to automatically import content from RSS or Atom feeds with the help of the Feeds module. The process relies on cron to run periodically so that the feed processor can check for new content. The feed processor creates regular Drupal nodes from the items contained in the feed. You can choose to have the imported items published by default or not. Once the items have been imported as nodes you can then create custom paths to those using Pathauto and/or customize the display using the Views module.

Note: Click the 'full screen' icon (to the right of the volume control) in order to watch online at full 1280x720 resolution.

Bookmark and Share Bookmark or Share Post

Creating An RSS Feed Using Views

This tutorial shows how to create an RSS feed from an existing view. See Creating A Page View From A Taxonomy to see how I created the initial page view.

Bookmark and Share Bookmark or Share Post

Adding RSS Only Fields

How (or even if) you use RSS on your Drupal site is a decision that all site builders should consciously make. I provided an overview of the RSS features in Drupal in a previous post. Since writing that post I have extended my use of RSS in Drupal via the CCK module.

One of the things that is new to CCK in Drupal 6 is the ability to add RSS specific display settings. The settings (pictured below) allow you to indicate whether a field that has been added with CCK should be displayed in the RSS feed or not. This feature allows an increased level of customization since you can choose what to display on a field-by-field basis. Some might choose to leave it alone and display everything in the RSS feed but some types of fields (like embed codes for instance) may not render well in RSS feed readers or when imported to other sites.

I'm using this feature to add a special "RSS Only" signature to items that are in the main RSS feeds on the site. The message won't be seen when people view the posts on my site but will be seen when content is consumed via the RSS feed, including when other sites import and display the content from the RSS feed.

There are a couple of good reasons to consider adding a signature to your Drupal RSS feeds. If your post contains additional content that might not be seen via the feed you can help the reader by letting them know that this is the case. You can also link to your content licensing guidelines to inform people what constitutes proper use. The second point is important these days since importing and re-distributing RSS content has become much more popular. While some sites like Drupal Planet aggregate as a service to the community, there are other spam sites that import content while placing banner ads all around it. Adding an RSS signature to your feeds can't prevent improper use of content, but it does serve notice that you may take action if someone does use your content improperly.

Creation of the RSS signature was very easy with the CCK module.

  • I added a new field with a type of 'text' and a form element of 'Text Area (Multiple Rows)'
  • I configured the field to be required and have a 'default value' that contained the message I wanted to add to my feeds
  • I edited the basic 'display fields' settings and set the field to 'hidden' for both the teaser and full node
  • I checked the rss 'display fields' and set the field to 'default'
Now when I create a new post I see the following field in my post editing view. I leave the field as is but I could edit it on a post-by-post basis if I wanted to.
 

The only shortcoming that I have found with this approach is that previous posts won't have the RSS signature added unless I go back an publish them again. This is certainly a case where an RSS signature module would be of great assistance. I don't have the skills as of yet to write such a module, so until one shows up this is the method that seems to work best.

Bookmark and Share Bookmark or Share Post

Drupal Feeds Worth Following

As we start 2009 I want to share some knowledge about how I keep up with what's going on in the Drupal community. Keeping up with the Drupal community is important to me because.I believe that in order to be successful in mastering Drupal you need to immerse your self in the world of Drupal.

One of the best ways to immerse yourself in Drupal is to keep track of the various sites where Drupal is discussed on a regular basis. I choose to keep track of my sites of choice by subscribing to RSS feeds. The concept of RSS may be new to people who are just getting started in web development. For the benefit of those people I've embedded a screencast below that shows how you can get started with RSS by using Google Reader.

  • Drupal.org Main Page - These are items posted to Drupal.org that get promoted to the main page of the site. These are usually very useful stories.
  • Drupal Search on Twitter - Lists all recent posts on Twitter that mention Drupal. This updates very frequently and will contain a lot of "noise" but can help you to find interesting people who are working with Drupal.
  • Drupal Planet - An aggregation of a large number of Drupal oriented posts combined into one feed.
  • Drupal on Delicious - Returns the latest 25 bookmarks saved on Delicious that were tagged with drupal.

There are lots more potential Drupal oriented feeds out there on sites like Flickr, YouTube and many others. I've found the four in my list to be the most interesting and/or helpful. Feel free to add feeds that you think are worth mentioning in the comments.

Google Reader Screencast

This video screencast will help you learn more about using Google Reader.

Bookmark and Share Bookmark or Share Post

Image Slideshow With The JW Image Rotator

There are a number of different ways to create image slideshows in Drupal. The Views Slideshow module is one option but doesn't seem to work with the Image module that I'm using on this site. Another option that looks very promising, and should work with Image, is the PicLens module by Cooliris.

I wanted to do something simpler to create a rotating image block on the front page of Learn By The Drop to showcase some of the Drupal screenshots that I've uploaded to my gallery. I decided to use the very simple JW Image Rotator as the tool to help me perform this task.

Step 1: I created a basic image gallery using the Image module. My gallery is located here. See this tutorial if you need guidance on how to do that.

Step 2: I used the Views module to create an RSS feed (http://learnbythedrop.com/gallery/feed) for my images. Check out my CCK and Views section for more information on the View module.

Step 3: I added and configured the Media RSS module because the JW Image Rotator reads the Media RSS element in order to display the proper photo.

Step 4: Download the JW Image Rotator and upload the files to a folder on your website.

Step 5: Add a new block to your Drupal site. Paste the appropriate embed code for the JW Image Rotator into the body of the block. Make sure that you have selected an input format of Full HTML. I have attached a sample file to this drop that you can use to start out. More information is available over on the JW Player Wiki.

Related Images

Example Block Views Configuration Views Styling
Bookmark and Share Bookmark or Share Post

Options For Importing Content

The ability to import content (also know as aggregation) from other sites is one of the great features of the Drupal platform. So while you can create content directly on your Drupal site you can also import and display content from other sites that contain RSS feeds or APIs (Application Programming Interfaces) that allow you to access their content.

Why Aggregate?

You might want to give the visitors to your site a bit of variety. If your site is about sports you may want to pull a feed containing sports news from Yahoo! Sports. You may be interested in creating your own network of blogs or podcasts. In that case you would pull updates from all of the sites in your network into your Drupal install. Or perhaps you're a prolific web publisher and want to create a lifestream to help people keep track of everything you publish. You can do all of these things using the Drupal platform.

Your Options

Drupal has lots of options for aggregating content. That's a good thing because it means people of different skill levels can get more of what they want. In general there are two types of aggregation modules for Drupal. One type captures content as nodes on your site. This means the content is searchable and will have a unique link. Another type displays a stream of content without importing as a full node. This type is not searchable and will link back to the originating site.

Bookmark and Share Bookmark or Share Post

Feed Aggregator Setup

This video shows you how to display content from RSS and Atom feeds on your site by using the core aggregator module. Includes instructions on how to display imported feed items in a block.

Bookmark and Share Bookmark or Share Post

Understanding RSS On Your Drupal Site

RSS IconOne of the best features of Drupal is the fact that the system generates many RSS feeds. RSS is great. It allows your visitors to subscribe to new content on your site in any number of ways. But sometimes the RSS capabilities of Drupal are a bit confusing to users. In this drop I'll do what I can to simplify the issue for you.

Front Page RSS Feed

Each Drupal site has a front page RSS feed that can be found at yoursite.com/rss.xml. This feed reflects items that have been promoted to the front page of your site. You can change the setting for this front page feed by going to admin/content/rss-publishing. Once there you can control the number of items in your feed. You can also change the setting for the RSS content by selecting Full Text, Titles or Titles Plus Teaser. Another benefit of the front page feed is the fact that current Internet Explorer and Mozilla browsers will auto-discover the feed when visitors arrive at the front page of your site.

Bookmark and Share Bookmark or Share Post

Using Google Tools To Extend Site Functions

Over the last couple of years I've come to rely on free tools from Google to assist with functionality on my Drupal powered websites. At first I just used Google's site search tool. Since then it seems that every couple of months Google has either released (or acquired) tools that can enhance your Drupal site.

Here is a list of the Google tools that I've used in conjunction with my various Drupal-powered websites.

Bookmark and Share Bookmark or Share Post
Syndicate content