I have been working with AngularJS and I am trying to connect my application to it.
So far I have used Slim PHP and can get all records from my MySql database but I
Hey everyone thanks for the input I was able to diagnose the issue!
using the network tab on chrome developer tools I saw that my code was sending the word "id" and not a variable.
I have now modified my controller by simply adding my route parameters onto the resource string. Seems to be working great now! Thank you everyone
app.controller('viewRequestController', function($scope, $location, $route, $routeParams, $resource) {
$scope.message = 'Pow!';
$scope.header = 'View Change Request';
var request_Id = $routeParams.id;
var Request = $resource(('http://pdgrosit02v/changeRequest/app/api/requests/'+ request_Id));
$scope.request = Request.get();
});