Hi 

 I am creating a web application having AngularJS as frontend and Perl as 
backend. I am using Perl Dancer and I am used to it but AngularJS is new to 
me. I am trying to make a simple RESTfull call to web app but It is not 
working. Below is the complete Code

### Angular JS Code ( index.tt )###

<div ng-app="myApp" ng-controller="customersCtrl"> <ul> <li ng-repeat="x in 
names"> {{ x.Name + ', ' + x.Country }} </li> </ul> </div> <script> var app 
= angular.module('myApp', []); app.controller('customersCtrl', 
function($scope, $http) { $http.get("http://localhost:5000/about";) 
.success(function (response) {$scope.names = response.records;}); }); 
</script>

####

$http Request to "http://localhost:5000/about"; is working fine and 
returning data in JSON format 

{"records": { "2":{"City":"México D.F.","Country":"Mexico","Name":"Ana 
Trujillo Emparedados y helados"}, "1":{"Name":"Alfreds 
Futterkiste","Country":"Germany","City":"Berlin"} } }

I am getting the blank page. :(


-- 
You received this message because you are subscribed to the Google Groups 
"AngularJS" group.
To unsubscribe from this group and stop receiving emails from it, send an email 
to [email protected].
To post to this group, send email to [email protected].
Visit this group at http://groups.google.com/group/angular.
For more options, visit https://groups.google.com/d/optout.

Reply via email to