From 9556a6101c5111c329ce1bcce606a07afefca1b3 Mon Sep 17 00:00:00 2001 From: Matthias Benkard Date: Thu, 8 Oct 2009 17:10:48 +0200 Subject: Fix the entry Atom feed. Ignore-this: 63b8785e4e3b69883f5825b8209dcb8b darcs-hash:7498821fb7e50a2032f0a224a03e36c0408a90ac --- journal.lisp | 51 +++++++++++++++++++++++++-------------------------- 1 file changed, 25 insertions(+), 26 deletions(-) diff --git a/journal.lisp b/journal.lisp index 1138cb0..401c2e8 100755 --- a/journal.lisp +++ b/journal.lisp @@ -142,33 +142,32 @@ "%4yr%-%2mon%-%2day%T%2hr%:%2min%:%2secZ%" time 0))) - (with-xml-output (*standard-output* :encoding "utf-8") - (with-slots (title date body categories last-modification id) - journal-entry - (with-tag ("entry") - (emit-simple-tags :title title - :id (format nil "urn:uuid:~(~A~)" - (uuid-of journal-entry)) - :updated (atom-time (or last-modification date)) - :published (atom-time date)) - (with-tag ("link" `(("rel" "alternate") - ("type" "text/html") - ("href" ,(link-to :view + (with-slots (title date body categories last-modification id) + journal-entry + (with-tag ("entry") + (emit-simple-tags :title title + :id (format nil "urn:uuid:~(~A~)" + (uuid-of journal-entry)) + :updated (atom-time (or last-modification date)) + :published (atom-time date)) + (with-tag ("link" `(("rel" "alternate") + ("type" "text/html") + ("href" ,(link-to :view + :post-id id + :absolute t))))) + (when include-edit-links + (with-tag ("link" `(("rel" "service.edit") + ("type" "application/atom+xml") + ("href" ,(link-to :view-atom-entry :post-id id - :absolute t))))) - (when include-edit-links - (with-tag ("link" `(("rel" "service.edit") - ("type" "application/atom+xml") - ("href" ,(link-to :view-atom-entry - :post-id id - :absolute t)) - ("title" ,title))))) - (when full-content - (with-tag ("content" `(("type" "xhtml") - ("xml:lang" "de") - ("xml:base" ,(link-to :index :absolute t)))) - (with-tag ("div" '(("xmlns" "http://www.w3.org/1999/xhtml"))) - (xml-as-is (journal-markup->html (body-of journal-entry)))))))))) + :absolute t)) + ("title" ,title))))) + (when full-content + (with-tag ("content" `(("type" "xhtml") + ("xml:lang" "de") + ("xml:base" ,(link-to :index :absolute t)))) + (with-tag ("div" '(("xmlns" "http://www.w3.org/1999/xhtml"))) + (xml-as-is (journal-markup->html (body-of journal-entry))))))))) #.(restore-sql-reader-syntax-state)) -- cgit v1.2.3