about summary refs log tree commit diff
diff options
context:
space:
mode:
authorVincent Ambo <v.ambo@me.com>2012-03-22T13·34+0100
committerVincent Ambo <v.ambo@me.com>2012-03-22T13·34+0100
commit6a8ffaf25a87905a9a6b15b26ffd1db03312d793 (patch)
tree74d5d2246ba22d4f80d7e0da1786721a16796ed3
parentf6f066a93e7f62846b5bac5d469f4f4c6170c351 (diff)
* cleaned up res/ folder
* serving static/ content from res/ with 20 years expiration date
* linen texture
-rw-r--r--res/blog.css1
-rw-r--r--res/blogstyle.css8
-rw-r--r--res/blogv31.css1
-rw-r--r--res/drama.wavbin208300 -> 0 bytes
-rw-r--r--res/ios-linen.jpgbin0 -> 6039 bytes
-rw-r--r--res/loginBoxTop.pngbin606 -> 0 bytes
-rw-r--r--res/twtbtn.pngbin8058 -> 0 bytes
-rw-r--r--src/Blog.hs6
-rw-r--r--src/Main.hs3
9 files changed, 11 insertions, 8 deletions
diff --git a/res/blog.css b/res/blog.css
deleted file mode 100644
index 7bad2c6049df..000000000000
--- a/res/blog.css
+++ /dev/null
@@ -1 +0,0 @@
-@charset UTF-8;@font-face{font-family:'PT Sans';font-style:normal;font-weight:400;src:local('PT Sans'), local(PTSans-Regular), url(http://themes.googleusercontent.com/static/fonts/ptsans/v2/7YGmE4Ls5b94ct65u07hVQLUuEpTyoUstqEm5AMlJo4.woff) format(woff);}html,body{margin:0;padding:0;}body{padding-top:10px;font-family:'PT Sans', sans-serif;min-height:850px;background-color:#4A525A;color:#EEE;}a{color:#000;}input,textarea,select{border:1px solid #555;font-size:15px;line-height:1.2em;width:550px;background:#F9F9F9;-webkit-border-radius:.5em;padding:.5em;}.header{z-index:4;padding-left:20px;padding-bottom:70px;padding-top:30px;position:relative;box-shadow:0 6px 5px 1px #848F9A;}.link{color:#EEE;}.middle{position:relative;z-index:2;display:block;width:100%;padding-top:40px;background-color:#EEE;color:#000;}.footer{z-index:4;position:relative;background-color:#4A525A;margin-top:30px;padding-top:20px;box-shadow:0 -6px 5px 1px #848F9A;color:#EEE;}.btitle{text-decoration:none;color:#EEE;font-size:x-large;font-weight:700;margin-top:15px;margin-bottom:10px;}.contacts{float:left;font-weight:bolder;}.righttext{float:right;padding-right:20px;}.rightbox{text-align:right;padding-right:14px;}.innerTitle{margin-left:10px;font-weight:700;}.innerBoxComments{margin-left:10px;}.innerContainer{padding-right:20px;}.centerbox{text-align:center;min-height:45px;}.cInput{margin-left:15px;}.tt{font-family:"courier new",courier,monospace;font-size:13px;}.cl{text-decoration:none;color:#000;}.cHead{font-size:large;font-weight:700;}.notFoundFace{text-align:center;font-size:100px;}.notFoundText{text-align:center;font-size:24px;font-weight:700;}
diff --git a/res/blogstyle.css b/res/blogstyle.css
index a74c9f1d07f8..9f5d69521e7e 100644
--- a/res/blogstyle.css
+++ b/res/blogstyle.css
@@ -14,10 +14,8 @@ html, body{
 }
 
 body {
-	padding-top: 10px;
 	font-family: 'PT Sans', sans-serif;
 	min-height: 850px;
-	background-color: #4A525A;
 	color: #EEE;
 }
 
@@ -37,12 +35,13 @@ input, textarea, select {
 
 /* site sections */
 .header {
+	background: url(/static/ios-linen.jpg);
 	z-index: 4;
 	padding-left: 20px;
 	padding-bottom: 70px;
 	padding-top:  30px;
 	position: relative;
-	box-shadow: 0 6px 5px 1px #848F9A;
+	box-shadow: 0 6px 5px 1px #343537;
 }
 
 .link {
@@ -60,12 +59,13 @@ input, textarea, select {
 }
 
 .footer {
+	background: url(/static/ios-linen.jpg);
 	z-index: 4;
 	position: relative;
 	background-color: #4A525A;
 	margin-top: 30px;
 	padding-top: 20px;
-	box-shadow: 0 -6px 5px 1px #848F9A;
+	box-shadow: 0 -6px 5px 1px #343537;
 	color: #EEE;
 }
 
diff --git a/res/blogv31.css b/res/blogv31.css
new file mode 100644
index 000000000000..15656b088131
--- /dev/null
+++ b/res/blogv31.css
@@ -0,0 +1 @@
+@charset UTF-8;@font-face{font-family:'PT Sans';font-style:normal;font-weight:400;src:local('PT Sans'), local(PTSans-Regular), url(http://themes.googleusercontent.com/static/fonts/ptsans/v2/7YGmE4Ls5b94ct65u07hVQLUuEpTyoUstqEm5AMlJo4.woff) format(woff);}html,body{margin:0;padding:0;}body{font-family:'PT Sans', sans-serif;min-height:850px;color:#EEE;}a{color:#000;}input,textarea,select{border:1px solid #555;font-size:15px;line-height:1.2em;width:550px;background:#F9F9F9;-webkit-border-radius:.5em;padding:.5em;}.header{background:url(/static/ios-linen.jpg);z-index:4;padding-left:20px;padding-bottom:70px;padding-top:30px;position:relative;box-shadow:0 6px 5px 1px #343537;}.link{color:#EEE;}.middle{position:relative;z-index:2;display:block;width:100%;padding-top:40px;background-color:#EEE;color:#000;}.footer{background:url(/static/ios-linen.jpg);z-index:4;position:relative;background-color:#4A525A;margin-top:30px;padding-top:20px;box-shadow:0 -6px 5px 1px #343537;color:#EEE;}.btitle{text-decoration:none;color:#EEE;font-size:x-large;font-weight:700;margin-top:15px;margin-bottom:10px;}.contacts{float:left;font-weight:bolder;}.righttext{float:right;padding-right:20px;}.rightbox{text-align:right;padding-right:14px;}.innerTitle{margin-left:10px;font-weight:700;}.innerBoxComments{margin-left:10px;}.innerContainer{padding-right:20px;}.centerbox{text-align:center;min-height:45px;}.cInput{margin-left:15px;}.tt{font-family:"courier new",courier,monospace;font-size:13px;}.cl{text-decoration:none;color:#000;}.cHead{font-size:large;font-weight:700;}.notFoundFace{text-align:center;font-size:100px;}.notFoundText{text-align:center;font-size:24px;font-weight:700;}
diff --git a/res/drama.wav b/res/drama.wav
deleted file mode 100644
index 20d326c5f40b..000000000000
--- a/res/drama.wav
+++ /dev/null
Binary files differdiff --git a/res/ios-linen.jpg b/res/ios-linen.jpg
new file mode 100644
index 000000000000..c03636fd1dd5
--- /dev/null
+++ b/res/ios-linen.jpg
Binary files differdiff --git a/res/loginBoxTop.png b/res/loginBoxTop.png
deleted file mode 100644
index 8a0ee3ba8d6f..000000000000
--- a/res/loginBoxTop.png
+++ /dev/null
Binary files differdiff --git a/res/twtbtn.png b/res/twtbtn.png
deleted file mode 100644
index 3a54c73c4c2c..000000000000
--- a/res/twtbtn.png
+++ /dev/null
Binary files differdiff --git a/src/Blog.hs b/src/Blog.hs
index 0e6ed519547b..7e719466a014 100644
--- a/src/Blog.hs
+++ b/src/Blog.hs
@@ -43,7 +43,7 @@ blogTemplate lang t_append body = H.docTypeHtml $ do --add body
     H.head $ do
         H.title $ (toHtml $ blogTitle lang t_append)
         H.link ! A.rel "alternate" ! A.type_ "application/rss+xml" ! A.title "RSS-Feed" ! A.href "/rss"
-        H.link ! A.rel "stylesheet" ! A.type_ "text/css" ! A.href "/res/blog.css" ! A.media "all"
+        H.link ! A.rel "stylesheet" ! A.type_ "text/css" ! A.href "/static/blogv31.css" ! A.media "all"
         H.meta ! A.httpEquiv "content-type" ! A.content "text/html;charset=UTF-8"
         --H.style ! A.type_ "text/css" ! A.title "iOS iMessage" ! A.media "screen and (max-device-width: 1024px)" $ "#cosx{display:none;}"
         preEscapedText analytics
@@ -175,7 +175,7 @@ showSiteNotice = H.docTypeHtml $ do
 adminTemplate :: Text -> Html -> Html
 adminTemplate title body = H.docTypeHtml $ do
     H.head $ do
-        H.link ! A.rel "stylesheet" ! A.type_ "text/css" ! A.href "/res/admin.css" ! A.media "all"
+        H.link ! A.rel "stylesheet" ! A.type_ "text/css" ! A.href "/static/admin.css" ! A.media "all"
         H.meta ! A.httpEquiv "content-type" ! A.content "text/html;charset=UTF-8"
         H.title $ toHtml $ T.append "TazBlog Admin: " title
     H.body
@@ -191,7 +191,7 @@ adminLogin = adminTemplate "Login" $
             ! A.name "account" -- ! A.value "tazjin" ! A.readonly "1"
         H.p $ "Passwort"
         H.p $ H.input ! A.type_ "password" ! A.style "font-size: 2;" ! A.name "password"
-        H.p $ H.input ! A.alt "Anmelden" ! A.type_ "image" ! A.src "/res/signin.gif"
+        H.p $ H.input ! A.alt "Anmelden" ! A.type_ "image" ! A.src "/static/signin.gif"
 
 adminIndex :: Text -> Html
 adminIndex sUser = adminTemplate "Index" $
diff --git a/src/Main.hs b/src/Main.hs
index f0c28b9b5bd2..f1bc9114a6cd 100644
--- a/src/Main.hs
+++ b/src/Main.hs
@@ -75,6 +75,9 @@ tazBlog acid = do
               ok $ toResponse $ adminIndex ("tazjin" :: Text)
          , dir "admin" $ ok $ toResponse $ adminLogin 
          , dir "dologin" $ processLogin acid
+         , do setHeaderM "cache-control" "max-age=630720000"
+              setHeaderM "expires" "Tue, 20 Jan 2037 04:20:42 GMT"
+              dir "static" $ serveDirectory DisableBrowsing [] "../res"
          , serveDirectory DisableBrowsing [] "../res"
          , notFound $ toResponse $ showError NotFound DE
          ]