Welcome to Squishdot Squishdot Websites How-To
 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
Squishdot Posted by Jonathan Mark on Friday February 09, @11:39PM
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>

Post Reply

Name
Email
Notify Notify me via email of responses to this message
Title
Comment
(Check those URLs! Don't forget the http://!)
Encoding
If none of the above mean anything to you, select 'Plain'!
Attachment
(You can attach a file to your reply which can then be retrieved by other readers.
Try to keep the file sizes below 500Kb in order to conserve network and server resources.)
Allowed HTML <B> <I> <P> <A> <LI> <OL> <UL> <EM> <BR> <TT> <HR> <STRONG> <BLOCKQUOTE> <DIV .*> <DIV> <P .*>
Important Stuff:
  • Note: Fields with bold titles are required.
  • Please try to keep posts on topic.
  • Try to reply to other people comments instead of starting new threads,
  • Read other people's messages before posting your own to avoid simply duplicating what has already been said.
  • Use a clear subject that describes what your message is about.
  • Please do not post offtopic, inflammatory, inappropriate, illegal, or offensive comments. Repeat offenders will be sanctioned.
  • Powered by Zope  Squishdot Powered
      "Any system that depends on reliability is unreliable." -- Nogg's Postulate
    All trademarks and copyrights on this page are owned by their respective companies. Comments are owned by the Poster. The Rest ©1999 Butch Landingin, ©2000-2002 Chris Withers.