Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- app.controller('AppCtrl', ['$scope', 'getTopicContent', function($scope,getTopicContent){
- getTopicContent.request().success(function(data, $scope){
- $scope.threadContent = data;
- });
- }]);
- app.factory('getTopicContent', ['$http', function($http, $scope){
- var query = function() {
- return $http({
- url: "http://www.corsproxy.com/mydata.me/level1/list.php",
- method: "GET"
- })
- }
- return {
- request : function(){
- return query();
- }
- }
- }]);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement