Skip to content

Instantly share code, notes, and snippets.

@KirinDave
Created December 8, 2009 23:20
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save KirinDave/dd83a434403e29fdf09d to your computer and use it in GitHub Desktop.
Save KirinDave/dd83a434403e29fdf09d to your computer and use it in GitHub Desktop.
<!DOCTYPE html>
<html>
<head>
<title></title>
<style type="text/css" media="screen">
body {
font-family: Times;
}
h2 {
font-size: 45pt;
text-align: center;
}
article {
position: absolute;
display: block;
border: solid 1px red;
width: 50%;
margin-left: 10%;
}
aside {
position: absolute;
left: 70%;;
width: 25%;
border: solid 1px black;
}
</style>
</head>
<body>
<header><h2>The Ladder</h2>
<article id="stats">
<section id="rankings">
<ol id="ladder">
<li> The ladder is empty.</li>
</ol>
</section>
</article>
<aside id="Menu">
<ul>
<li>Enter A Game</li>
<li>Enter A User</li>
</ul>
</aside>
</body>
(ns kirindave.foosball.server
(:use [kirindave.foosball player]
[clojure.contrib str-utils seq-utils duck-streams]
[compojure])
(:require [net.cgrand.enlive-html :as html]))
(def *templates-dir* "/Users/kirindave/Projects/scorekeeper/templates/")
; Templates
(println (str *templates-dir* "home.html"))
(html/deftemplate homepage (str *templates-dir* "home.html") [x]
[:title] (html/content "Whee"))
(defroutes greeter
(GET "/" (apply str (homepage 1))))
(defn start-server []
(run-server {:port 8081} "/*" (servlet greeter)))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment