From cb2d9ecc1352901421d0d85430bc3582038ba1cd Mon Sep 17 00:00:00 2001 From: bg66 Date: Wed, 14 Mar 2007 08:10:56 +0000 Subject: [PATCH] * mixi-atom.el (mixi-make-atom): Use `concat' instead of `insert'. (mixi-atom-cgi): New function. (mixi-atom-file): Rename from `mixi-make-atom-file'. --- ChangeLog | 6 ++++++ mixi-atom.el | 15 +++++++++++---- 2 files changed, 17 insertions(+), 4 deletions(-) diff --git a/ChangeLog b/ChangeLog index 400231b..4b13e9e 100644 --- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,9 @@ +2007-03-14 OHASHI Akira + + * mixi-atom.el (mixi-make-atom): Use `concat' instead of `insert'. + (mixi-atom-cgi): New function. + (mixi-atom-file): Rename from `mixi-make-atom-file'. + 2007-03-12 OHASHI Akira * mixi-atom.el (mixi-atom-file): New user option. diff --git a/mixi-atom.el b/mixi-atom.el index 2ac5e12..3c955e9 100644 --- a/mixi-atom.el +++ b/mixi-atom.el @@ -116,10 +116,9 @@ RANGE is the range for getting articles. If RANGE is nil, get all articles." objects) entries)) -;;;###autoload (defun mixi-make-atom () "Make Atom Syndication Format" - (insert "\n" "\n" "\n" @@ -146,9 +145,17 @@ RANGE is the range for getting articles. If RANGE is nil, get all articles." "\n")) ;;;###autoload -(defun mixi-make-atom-file () +(defun mixi-atom-cgi () + (princ (concat "Content-Type: application/atom+xml; charset=" + (symbol-name mixi-atom-coding-system) "\n" + "\n" + (encode-coding-string (mixi-make-atom) + mixi-atom-coding-system)))) + +;;;###autoload +(defun mixi-atom-file () (with-temp-buffer - (mixi-make-atom) + (insert (mixi-make-atom)) (let ((coding-system-for-write mixi-atom-coding-system) (file (expand-file-name mixi-atom-file))) (write-region (point-min) (point-max) file)))) -- 1.7.10.4