Does anyone know why this does not work?  $http     .get('accept.php', {         source: link,         category_id: category     })     .success(function (data, status) {         $scope.info_show = data     });   and this does work:  $http...
I'm having trouble moving my Angular 1 JavaScript service to a Angular 2 TypeScript service using http to make a CORS request (this is using Ionic version 2). In Angular 1, I do something like this.  angular.module('app.services',[]) .fac...
In AngularJS for sending a request I use the builtin $http service.   What shall I use for sending a request to a server in Angular? I can't find any doc that covers the subject....
I'm sending a custom header from server in a response. In $http response interceptor I want to get this header, but the only header I could get is Content-type header. How can I resolve my problem?  Piece of my $http interceptor:  response: funct...
How can I handle an HTTP error, e.g. 500, when using the AngularJS "http get then" construct (promises)?  $http.get(url).then(     function(response) {         console.log('get',response)     } )   Problem is, for any non 200 HTTP res...
I load some binary data using   $http.post(url, data, { responseType: "arraybuffer" }).success(             function (data) { /*  */ });   In case of an error, the server responds with an error JSON object like  { "message" : "som...
I'm working on an angularJS app and this is my first website using this framework. In my app i've a need to make a $http call inside a for loop. With in the loop before the next iteration I want to wait for the response from my previous call....
I am trying to add a custom header to my angular js GET request as below:      $http({         method : 'GET',         url : s,         headers : {         "partnerId" : 221,          "partnerKey" : "heeHBcntCKZwVsQo"...
Within a factory service, I have to use      $http.get(url, { cache: true })   In my view, i am using ng-if or ng-show to trigger a CSS transition.   The problem :  It is working great for the first request, but obviously for the next request of the...
I have a ng-repeat loop for a number of values. While looping, I fetch a variable from another array of values and use that:  <div ng-repeat="i in [1,2,3]">     <div ng-init="obj = getObject(i)">         <pre>{{ obj...

Tags

Recent Questions

Top Questions

Home Tags Terms of Service Privacy Policy DMCA Contact Us

©2020 All rights reserved.