I want to change angular url to /jobs/id. i wrote like below one. will this work?
$location.path("/JobHire/jobs/"+response.data.id);
how should i write route config? i configured like this
$routeProvider
.when('/jobs/:id',{
templateUrl:'partials/job.html'
})
.otherwise({
redirectTo:'/'
});
$locationProvider.html5Mode(true);
Is this a correct way. How to retrieve those parameters inside a controller.