I am new in phonegap app development. I want to create an app that will communicate (CRUD operations) with server. I have created a json using php. now I want to access that file using angularJS. But can't access that file ("http://apptest.byethost5.com/view.php") from server. But localhost gives me the correct result. I think there has some permission problem to that file. I have changed the file permission to 755 but that does not work. Can you please suggest the correct way to deal with this problem.
<script src="http://ajax.googleapis.com/ajax/libs/angularjs/1.4.8/angular.min.js"></script>
<body>
<div ng-app="myApp" ng-controller="customersCtrl">
<table>
<tr ng-repeat="x in names">
<td>{{ x.firstname }}</td>
<td>{{ x.lastname }}</td>
</tr>
</table>
</div>
<script>
var app = angular.module('myApp', []);
app.controller('customersCtrl', function($scope, $http) {
$http.get("http://apptest.byethost5.com/view.php")
.then(function (response) {$scope.names = response.data.records;});
});
</script>
</body>