You are using an ajax request which does not follow the same rules as a normal 
browser navigation requests. It will not follow redirects for example.

I don't know what ajax lib you are using but the general solution will be:

fire request
wait for response
check response code of request
if redirect get location header
do cleanup of your local app
then set document.location.href to location url
the page will unload and load /login as "normal"

or you could rewrite the server to not send a redirect but send the location 
encoded as data.

HTH,
/thomas



> 
> The response to curl is as follows:
> 
> HTTP/1.1 302 Found
> Server: undertow
> X-XSS-Protection: 1; mode=block
> Location: http://localhost:3000/login  <---------
> X-Frame-Options: SAMEORIGIN
> Date: Fri, 11 Sep 2015 21:06:28 GMT
> Connection: keep-alive
> X-Content-Type-Options: nosniff
> Content-Type: text/html; charset=utf-8  <----------------
> Content-Length: 0
> 
> However, the reagent form is not getting redirected to he /login form.  It 
> remains in the same form.  On the console, I can see, however, the login page 
> is streamed as an HTML. ( I am using "/login" as just as an example.).
> 
> The original reagent page is doing a request with CLJS-AJAX POST.
> 
> Any hint is much appreciated.  Thanks,
> 
> Regards,
> Hari

-- 
Note that posts from new members are moderated - please be patient with your 
first post.
--- 
You received this message because you are subscribed to the Google Groups 
"ClojureScript" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to clojurescript+unsubscr...@googlegroups.com.
To post to this group, send email to clojurescript@googlegroups.com.
Visit this group at http://groups.google.com/group/clojurescript.

Reply via email to