13.7 Creating Your Own RSS Content

RSS allows you to aggregate like items, though you don't have to restrict this to web pages and news sources and things like that. For instance, one effective use of RSS would be to keep lists of multimedia recommendations such as books, music, and movies.

I use RSS to maintain a list of book recommendations from friends. For the most part, the RSS elements and the DC module define most of the data I want to capture, including the dc:creator, dc:subject, and the standard RSS channel, items, and item. However, within the core RSS 1.0 specification, a few useful fields are missing. Among these are elements to record who made the recommendation, the URL of her web site, whether the book has been read (or the movie has been viewed), and an URL of the review if any. Since the business I'm interested in documenting?book recommendations?isn't fully covered or predefined in any existing RDF vocabulary or within any existing RSS 1.0 module I could find, I created one of my own, with the following namespace:


I then defined the following elements in the namespace:


Name of person who made the recommendation (optional), PCDATA


Status of recommendation (required; 1=consumed, 0=unconsumed)


URL of web site of recommendation or recommender (optional)


URL of review (optional)

I asked around with some of my friends and ended up with a selection of book recommendations, which I then recorded in my newly extended RSS. Example 13-5 shows an abbreviated book recommendations list.

Example 13-5. Book recommendation RSS
<?xml version="1.0"?>


<channel rdf:about="http://weblog.burningbird.net/books.rdf">
<title>Burningbird BookList</title>
Burningbird's To Be Read Booklist and Recommendations

<rdf:li rdf:resource="http://isbn.nu/0395489016" />
<rdf:li rdf:resource="http://isbn.nu/0446391301" />
<rdf:li rdf:resource="http://isbn.nu/0679454519" />
<rdf:li rdf:resource="http://isbn.nu/0743418174" />
<rdf:li rdf:resource="http://isbn.nu/0553211161" />


<item rdf:about="http://isbn.nu/0446391301">
<title>Geek Love</title>
<dc:creator>Katherine Dunn</dc:creator>
<recs:recby>Denise Howell</recs:recby>

<item rdf:about="http://isbn.nu/0743418174">                                 
<title>Good in Bed</title>
<dc:creator>Jennifer Weiner</dc:creator>   

<item rdf:about="http://isbn.nu/0553211161">                                 
<title>Leaves of Grass</title>
<dc:creator>Walt Whitman</dc:creator>   

<item rdf:about="http://isbn.nu/0679742115/">
<dc:creator>Nicholson Baker</dc:creator>
<recs:recby>Karl aka Paradox1x</recs:recby>

<item rdf:about="http://isbn.nu/0395489016">                
<title>Let Us Now Praise Famous Men</title>
<dc:creator>James Agee, Walker Evans</dc:creator>
<recs:recby>Jonathon Delacour</recs:recby>


Though there is no description for each of the book items, the description elements are still listed because this element is mandatory. Of course, the next step to take would be to formalize the Recommendations module through the RSS Working Group, but for now, we'll accept it the way it is. In the next section, we'll look at a couple of different applications to process this data.