Using LOOP in HTML Generation Facility macro "html"

"George P.Taylor IX" <[email protected]> Sun, 29 Jun 2008 16:49:32 +0900
Newsgroups gmane.lisp.open-source.franz
Message-ID <[email protected]>
I am trying to use the html macro in the HTML Generation Facility.

I seem to be misunderstanding something, and would appreciate some help.

I have defined and evaluated a test form as

(publish :path "/testform"
         :content-type "text/html"
         :function
         #'(lambda (req ent)
             (with-http-response (req ent)
               (with-http-body (req ent)
                 (html (:html
                        (:head (:title "Test Form"))
                        (:body
                         ((:form :action "testform")

			(:princ 1)

                          ))))))))

And this works as expected.

However, when I try to use a loop to iterate over a set, I get no output to
a browser.

(publish :path "/testform2"
         :content-type "text/html"
         :function
         #'(lambda (req ent)
             (with-http-response (req ent)
               (with-http-body (req ent)
                 (html (:html
                        (:head (:title "Test Form 2"))
                        (:body
                         ((:form :action "testform2")

			 (loop for i from 1 to 10
                      		      do (:princ i))

                          ))))))))


Thanks for any help.

Best,

Jud