I am attempting to connect my angularJS app to a web service which i have created. The web service has a switch statement which selects the correct php file depending on the parameters you pass it. In this instance i am looking to pass action, retrieve to the web service. How can make my $http.get pass through parameters which will be read by my switch statement
Call to Webservice
function customersController($scope,$http) {
$http.get("http://10.137.98.144")
.success(function(response) {$scope.names = response;});
}
WebService
switch ($_POST['action'])
{
case 'retrieve':
require "retrieve.php";
retrieve();
break;
}