On Monday, May 4, 2015 at 11:34:26 AM UTC-4, clifford wrote:
>
> Hi
>
> I am using juxt/bidi for route matching.
>
> with the following routes:
>
>> (def routes ["/" {"index.html" :index
>> "articles/" {"index.html" :article-index
>> [:id] :article}}])
>
>
> It correctly matches at the REPL.
>
>> (match-route routes "/articles/4")
>> => {:handler :article, :route-params {:id "4"}}
>
>
> However in the browser, when I hit the url, localhost:3000/articles/4
> It attempts to download a file with name "4", can anybody let me know what
> I'm doing wrong here?
>
> Clifford
>
What is the Content-Type returned by that URL? If it's not text/html and
the URL doesn't end with ".html" the browser will do that, even if the
server is in fact responding with the article page. I don't know why the
Content-Type would be wrong (or missing) though.
--
You received this message because you are subscribed to the Google
Groups "Clojure" group.
To post to this group, send email to [email protected]
Note that posts from new members are moderated - please be patient with your
first post.
To unsubscribe from this group, send email to
[email protected]
For more options, visit this group at
http://groups.google.com/group/clojure?hl=en
---
You received this message because you are subscribed to the Google Groups
"Clojure" group.
To unsubscribe from this group and stop receiving emails from it, send an email
to [email protected].
For more options, visit https://groups.google.com/d/optout.