posts.lisp 528 Bytes
Newer Older
Ioanna M. Dimitriou H.'s avatar
wip  
Ioanna M. Dimitriou H. committed
1 2 3 4
;;;;posts.lisp

(in-package :ioa.re.posts)

5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21
;;; Manually creating and collecting post dispatchers.

(defun get-post-dispatchers ()
  (list
   (hunchentoot:create-prefix-dispatcher
    "/post/2019-09-13-hello-world-again"
    'hello-world-again-handler)))

;; hello-world

(defun hello-world-again-handler ()
  (with-output-to-string (stream)
    (html-template:fill-and-print-template
     #P"ioa.tmpl"
     (list :title "hello world, again"
	   :template '((#P"post/2019-09-13-hello-world-again.tmpl")))
     :stream stream)))