noir

    3热度

    1回答

    我一直在一个web项目中使用noir,并且根据他们的访问级别(以及sublevel)来定义由defpage宏定义的所有可能的路由,我想到了限制对用户的访问。所以,我原本 (defpage [:post "/mysite"] {:as input} (if-not (has-reqd-user-level? :levelX :sublevelY "/grantedRoute")

    2热度

    2回答

    我对clojure/compojure相当陌生,但真的很喜欢它。自然,我开始用Noir堆栈进行探索。已经写了一个POC应用程序。然后,发现解放者 - 有很多意义。只是想知道,如果有人曾经将Noir应用程序迁移到Liberator之前。任何有关此文章/博客的参考资料都将受到高度赞赏。

    0热度

    1回答

    我想不出我无法在noir应用程序中加载css。 既不能改变css soure文件,路线有什么问题吗? (ns my-web.views.common (:use noir.core hiccup.core hiccup.page-helpers )) (defpartial layout [& content] (html5

    1热度

    1回答

    我想向我的noir服务器发送一个post请求,但我有太多的参数,服务器只是响应413状态码。我想知道是否可以提高发布请求的字符数限制。我读它可能与其他服务如What is the size limit of a post request?和Clojure/Ring: Using the ring jetty adapter, large requests give me a 413: FULL H

    0热度

    2回答

    规则我有动态生成的形式,所以我试图验证他们这样说: (defn valid? [media-id data] ;media-id it's just a number, data is the form input (let [fields (common/get-fields-to-show media-id)] ; list of strings (the field names)

    4热度

    2回答

    我正在用Ring + Compojure + lib-noir尝试Clojure Web开发,我无法弄清楚如何测试会话状态。

    0热度

    1回答

    我正在尝试在webnoir中执行此操作。 这工作: (defpage [:post "/testurl] {:keys [name phone]} (html5 (str "name: " name) (str "phone: " phone))) 现在我想产生许多模块defpages,每个人都有不同的字段列表。我想从函数中调用defpages。 defpage必

    0热度

    1回答

    我使用黑色。 有: (defpage "/welcome" [] "Welcome to Noir!") 我做我做这两个网址的工作原理: http://localhost:8080/welcome http://localhost:8080/welcome/ 谢谢!编辑: 这是完整的答案。 在server.clj,加起来(:use [ring.util.response :only [r

    2热度

    2回答

    我在Clojure中搞乱了Noir网络框架,并试图生成一个随机的网格。 这可能是很糟糕的代码,但我正在学习! :d (def tiles [:stairs :stone :monster]) (defpage "/" [] (common/layout [:div {:class "level"} (repeatedly 10 [:div {:class "r

    3热度

    1回答

    我有一个照片链接列表,并且想用clojure和noir生成img标签。 在这里,我得到的链接: (def photos (->> (get-in result ["photoset" "photo"]) (map #(str "http://farm"(get % "farm") ".staticflickr.com/"(get % "server")"/"(get % "id")"_"(ge