title: Angular $http difference between .success() and .then()
body: <p>Sometimes I have trouble to fetch my data using $http service. And I did not 100% understand the main difference between .success() and .then()</p>
  
  <p>The following is an example that I can fetch the data using $http().then(), but I can't fetch my data using $http().success(). Can anyone explain why?</p>
  
  <p>Code using $http.success()  <a href="http://jsfiddle.net/xoonpLte/11/" rel="nofollow">http://jsfiddle.net/xoonpLte/11/</a></p>
  
  <pre><code>var manuRep = angular.module('manuRep', ['ui.bootstrap']);
    manuRep.controller('MyAppController', function($scope, $http) {
      $http.get('https://dl.dropboxusercontent.com/u/59954187/jobs.json').
        success(function(response) {
          $scope.cats = response.data;    
        }).
        error(function(error){
          alert(JSON.stringify(error));
        return error;
        });
    });
  </code></pre>
  
  <p>Code using $http.then() <a href="http://jsfiddle.net/xoonpLte/12/" rel="nofollow">http://jsfiddle.net/xoonpLte/12/</a></p>
  
  <pre><code>var manuRep = angular.module('manuRep', ['ui.bootstrap']);
    manuRep.controller('MyAppController', function($scope, $http) {
      $http.get('https://dl.dropboxusercontent.com/u/59954187/jobs.json').
        then(function(response) {
          $scope.cats = response.data;    
        });
    });
  </code></pre>