#import time #from urlparse import urljoin #from xml.sax.saxutils import escape #from template import authorFor, iso8601, html2xml Content-Type: application/rdf+xml; charset=utf-8 $channel.title $channel.link $channel.description.encode('utf-8') $channel.author $iso8601() $channel.language Copyright $time.strftime("%Y") $channel.title #for $item in $Items #end for #for $item in $Items #set $author=authorFor($item.content) $html2xml($item.title) $urljoin($channel.link,$item.link) #if $item.description <> $item.content $escape($item.description) #end if $escape($item.content) $iso8601($item.mtime) $item.comments #if $author $author #end if #end for