diff options
author | Matthias Andreas Benkard <code@mail.matthias.benkard.de> | 2012-02-26 02:11:01 +0100 |
---|---|---|
committer | Matthias Andreas Benkard <code@mail.matthias.benkard.de> | 2012-02-26 02:11:01 +0100 |
commit | ddafd8ec54645144768b3edd2e50c264f2d19694 (patch) | |
tree | 9f9b71b1a717ed9e34601ecd38163cc4e2c9a602 /src | |
parent | 4199a922e578a008d455bd36cd166f7f05a7d7b5 (diff) |
Move most <script/> tags to the bottom of pages.
Diffstat (limited to 'src')
-rw-r--r-- | src/mulk/benki/auth.clj | 15 | ||||
-rw-r--r-- | src/mulk/benki/util.clj | 3 | ||||
-rw-r--r-- | src/mulk/benki/wiki.clj | 4 |
3 files changed, 14 insertions, 8 deletions
diff --git a/src/mulk/benki/auth.clj b/src/mulk/benki/auth.clj index ee3c762..211d88a 100644 --- a/src/mulk/benki/auth.clj +++ b/src/mulk/benki/auth.clj @@ -68,12 +68,15 @@ (redirect (.getDestinationUrl authreq true)))) (def login-page-layout - {:head (list - [:link {:type "text/css", :rel "stylesheet", :href (resolve-uri "/3rdparty/openid-selector/css/openid.css")}] - [:script {:type "text/javascript", :src (resolve-uri "/3rdparty/openid-selector/js/openid-jquery.js")}] - [:script {:type "text/javascript", :src (resolve-uri "/3rdparty/openid-selector/js/openid-en.js")}] - [:script {:type "text/javascript", :src (resolve-uri "/js/openid-login.js")}] - )}) + {:head + (list + [:link {:type "text/css", :rel "stylesheet", :href (resolve-uri "/3rdparty/openid-selector/css/openid.css")}]) + :bottom + (list + [:script {:type "text/javascript", :src (resolve-uri "/3rdparty/openid-selector/js/openid-jquery.js")}] + [:script {:type "text/javascript", :src (resolve-uri "/3rdparty/openid-selector/js/openid-en.js")}] + [:script {:type "text/javascript", :src (resolve-uri "/js/openid-login.js")}] + )}) (defpage "/login" [] (layout login-page-layout "Benki Login" diff --git a/src/mulk/benki/util.clj b/src/mulk/benki/util.clj index 4dac73b..5c7cd97 100644 --- a/src/mulk/benki/util.clj +++ b/src/mulk/benki/util.clj @@ -32,7 +32,8 @@ :src (resolve-uri "/3rdparty/jquery/jquery-1.7.min.js")}] (:head kind)] [:body [:h1 title] - content])) + content + (:bottom kind)])) (defn fresolve [s & args] diff --git a/src/mulk/benki/wiki.clj b/src/mulk/benki/wiki.clj index 29e99ce..ad29807 100644 --- a/src/mulk/benki/wiki.clj +++ b/src/mulk/benki/wiki.clj @@ -48,7 +48,9 @@ ;; Aloha Editor (list [:link {:rel "stylesheet" - :href (resolve-uri "/3rdparty/alohaeditor/aloha/css/aloha.css")}] + :href (resolve-uri "/3rdparty/alohaeditor/aloha/css/aloha.css")}]) + :bottom + (list [:script {:type "text/javascript" :src (resolve-uri "/3rdparty/alohaeditor/aloha/lib/aloha.js") :data-aloha-plugins "common/format,common/highlighteditables,common/list,common/link,common/undo,common/paste,common/block,common/table"}] |