I am using an $http.post call to my server and sending over some user data:
$http.post('/streamdb/create/',{user:$scope.user.username})
My server then performs a series of operations and retrieves a certain id from the DB. I would like to have the client redirected to the page ('streams/'+id), so I have the operations terminate with a
res.redirect('/streams/'+id)
I could send over the id:
res.json({id:id})
and then respond to a .success() clause with a $location, or window.open (as seen here, or here) but that seems a little wasteful: the server already knows where to send me, why should I make an additional call?
While the server shows that the routing was done, the new page never renders, it just stays on the original page.
Thanks for any help!