I’m trying to create a POST handler which get a key in the URI, and a value in the message body.
This is what I use from ClojureScript (with jayq)
(let [url “http://localhost:8086/5684ad00-02bc-49d7-9993-957573fd8765”]
(ajax url {:async true :type "POST" :data “text”)}))
This is what I have on the server side:
(POST "/:guid" {body :body}
(str "stored:" (slurp body))
)
And I use (wrap-params) on the handler.
The request seems to be OK, but I fail to parse the body.
Can I even do that, or should I pass both parameters in body or in req-uri?
Thanks
--
You received this message because you are subscribed to the Google Groups "Compojure" group.
To unsubscribe from this group and stop receiving emails from it, send an email to compojure+...@googlegroups.com.
To post to this group, send email to comp...@googlegroups.com.
Visit this group at http://groups.google.com/group/compojure?hl=en.
For more options, visit https://groups.google.com/groups/opt_out.
Thanks James
Works like a charm.
Your help is much appreciated!