Skip to content

Instantly share code, notes, and snippets.

@making
Created December 3, 2009 17:44
Show Gist options
  • Save making/248361 to your computer and use it in GitHub Desktop.
Save making/248361 to your computer and use it in GitHub Desktop.
(defmacro with-layout ((&key (header *header-html*)
(side *side-html*)
(footer *footer-html*)
(title "title here")
(css "/css/main.css")
)
&body body)
`(cl-who:with-html-output-to-string (*standard-output* nil :prologue nil :indent t)
(:html
(:head (:title ,title)
(:link :rel "stylesheet" :type "text/css" :href ,css)
)
(:body
(:div
:id "body"
(:div
:id "header"
,@header
)
(:div
:id "navigation"
,@side
)
(:div
:id "contents"
,@body
)
(:div
:id "footer"
,@footer
)
)
)
)
)
)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment