about
search
post article
Documentation
Mailing Lists
Bug Tracking
Development
Installation
Upgrading
Download
admin
rdf
main
|
Here Is A DTML Method For Squishdot Which Produces An Atom 1.0 Feed |
Posted by Jonathan Mark on Friday February 09, 11:39PM, 2007
from the Time to upgrade to a modern syndication method dept.
Here is a DTML method called posting_xml. If you place it in the same directory as your Squishdot 1.5 index_html page it will produce an Atom 1.0 feed. It will display the same articles as index_html does.
I tested it on Zope 2.62 but it should work anywhere.
<dtml-comment >
<!-- version : 1.0
author : Jonathan Mark
e-mail : jonathansamuel@yahoo.com
URL : goodbyejim.com
Date : Feb. 8, 2007
-->
</dtml-comment><dtml-call "RESPONSE.setHeader('Content-Type','application/atom+xml; charset=utf-8')">
<?xml version="1.0" encoding="utf-8"?>
<?xml-stylesheet href="http://planetatom.net/css/atom.css" type = "text/css"?>
<feed xmlns="http://www.w3.org/2005/Atom" xmlns:l="http://purl.org/rss/1.0/modules/link/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:pe="http://purl.org/atompub/person-extensions/1.0" xmlns:thr="http://purl.org/syndication/thread/1.0">
<id><dtml-var site_url>/</id>
<title type="text"><dtml-var site_name></title>
<updated><dtml-var "this().posting_xml.bobobase_modification_time()" fmt="20%y-%m-%dT%H:%M:%SZ"></updated>
<author><name><dtml-var admin_name></name></author>
<link href="<dtml-var site_url>/posting_xml" rel="self" title="<dtml-var site_name>" type="application/atom+xml"/>
<generator uri="/zope.org" version="2.62">
Created By Zope
</generator>
<dtml-in item_list>
<entry>
<title type="text"><dtml-var title></title>
<link href ="<dtml-var thread_path>/<dtml-var id>/index_html"/>
<author><name><dtml-var author>, <dtml-var email></name></author>
<id><dtml-var URL1 ><dtml-var thread_path>/<dtml-var id>/index_html</id>
<category term ="<dtml-var subject html_quote>"/>
<updated><dtml-var "date_posted(fmstr='20%y-%m-%dT%H:%M:%SZ')"></updated>
<content type = "html"><![CDATA[<ul><b><dtml-var dept></b></ul><dtml-var showSummary><p><dtml-var showBody>]]></content>
</entry>
</dtml-in item_list>
</feed>
<
Spam from Avangate.com?
|
Spam at my squishdot siite
>
|
Related Links |
|
|