I'm doing authentication and authorization in the server side.
In angularJs I'm doing the routing using the routeProvider like this.
$routeProvider.
when('/', {
templateUrl: 'partials/_home',
controller: 'HomeCtrl'
}).
when('/home', {
templateUrl: 'partials/_home',
controller: 'HomeCtrl'
}).
when('/users', {
templateUrl: 'partials/_users',
controller: 'UserCtrl'
}).
when('/users/:id', {
templateUrl: 'partials/_userForm',
controller: 'UserCtrl'
}).
otherwise({
redirectTo: '/'
});
And here is the problem to solve, when I get a 403 angular is not showing the server page, it just does not do nothing.
Did some one has a suggestion of how to handle this?
/test/partials/_userForm
– what you have in response? It has nothing in common with AngularJS, it is your server. What you expect from Angular if 403 happens? Redirect to some login page? – Compensatory