require 'rss'
include RSS

chan = RSS::Channel.new
chan.title = "Test Channel"
chan.language = "en-us"
chan.link = "http://www.chadfowler.com"
chan.description  = "An example RSS Channel"

img = RSS::Image.new
img.title = "RSS is AOK"
img.link = "http://www.chadfowler.com"
img.url = "http://www.chadfowler.com/logo.jpg"
chan.image = img

item = RSS::Item.new
item.title = "A test post"
item.link = "http://www.chadfowler.com/a"
chan.add_item item

item2 = RSS::Item.new
item2.title = "Another post"
item2.link = "http://www.chadfowler.com/b"
chan.add_item item2

item3 = RSS::Item.new
item3.title = "I like Ruby"
item3.link = "http://www.chadfowler.com/c"
chan.add_item item3

item4 = RSS::Item.new
item4.title = "The last one"
item4.link = "http://www.chadfowler.com/d"
chan.add_item item4

print chan.to_xml 


