annotate buy_temp.clj @ 72:83b0419c7979 laserkard

implemented temporary buy page in clojure
author Robert McIntyre <rlm@mit.edu>
date Wed, 23 Jun 2010 01:01:40 -0400
parents ad52bd1a084b
children 5fb0e5db5926
rev   line source
rlm@71 1 (ns laserkard.buy-temp
rlm@71 2
rlm@71 3 (:use (compojure.http request servlet session routes)
rlm@71 4 (compojure.server jetty)
rlm@71 5 (compojure control)
rlm@72 6 (clojure.contrib prxml str-utils duck-streams)
rlm@71 7 ))
rlm@71 8
rlm@71 9 (defn pxml [ & args]
rlm@71 10 (with-out-str (apply prxml args)))
rlm@72 11
rlm@72 12 (defn header []
rlm@72 13 (pxml [:doctype! "html PUBLIC \"-//W3C//DTD XHTML 1.0 Transitional//EN\" \"http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd\""]))
rlm@72 14
rlm@72 15
rlm@72 16 (defn buy-gen []
rlm@72 17
rlm@72 18
rlm@72 19 (str
rlm@72 20 (header)
rlm@72 21 (re-gsub
rlm@72 22 #">" ">\n"
rlm@72 23 (pxml
rlm@72 24 [:html {:xmlns "http://www.w3.org/1999/xhtml"}
rlm@72 25
rlm@72 26 [:head
rlm@72 27 [:meta {:http-equiv "Content-Type" :content "text/html" :charset "UTF-8"}]
rlm@72 28 [:link {:rel "stylesheet" :href "main.css" :type "text/css" :media "screen"}]
rlm@72 29 [:link {:rel "stylesheet" :href "old_sexy.css" :type "text/css" :media "screen"}]
rlm@72 30 [:link {:rel "stylesheet" :href "faq.css" :type "text/css" :media "screen"}]
rlm@72 31 ]
rlm@72 32 [:body
rlm@72 33 [:raw! (slurp "/home/r/Desktop/web/laserkard/top_menu.include")]
rlm@72 34 [:div {:class "whole"}
rlm@72 35 [:div {:id "pokedex"}
rlm@72 36 [:p "We have run out of supplies. LaserKards will be
rlm@72 37 available shortly once additional materials have arrived!"]]]]]
rlm@72 38 ))))
rlm@72 39
rlm@72 40
rlm@72 41