Skip to main content
0 votes
2 answers
598 views

Angular 8.3.20 HttpClient refuse/fail while response returns 200 OK

I have create my api/product-search.php backend in http://localhost/ like so: <?php header('Access-Control-Allow-Origin', '*'); header("Access-Control-Allow-Headers: Content-Type"); header("Access-...
user12505305's user avatar
1 vote
2 answers
3k views

Angular 8 subscribe on finish of multiple succeeding requests, how to?

I have an auth service with a login method and a login component. From my login components' onSubmit method I call the services' login method and subscribe to the answer. The challenging part is, ...
Allisone's user avatar
  • 9,154
-2 votes
1 answer
56 views

when ad add code on my file as it is on video i get error "./src/app/app.module.ts Module not found: Error: Can't resolve '@angular/http'"

i am new in angular world. i trying to learn this framework but it is so HARD!... so in my first example i got error: import { BrowserModule } from '@angular/platform-browser'; import { NgModule } ...
გენო მუმლაძე's user avatar
11 votes
2 answers
31k views

Can't have a timeout of over 2 minutes with this.http.get? [duplicate]

My angular 4.3.2 code is calling my back-end service that takes 2-4 minutes to return. Using just the default this.http.get code, I see that the default timeout kicks in after 2 minutes. However when ...
Mike K.'s user avatar
  • 616
2 votes
1 answer
215 views

Rxjs Async Interceptors - Keep on getting an error

I need to add a token to the request in my interceptor. I keep on getting the error core.js:1673 ERROR TypeError: You provided 'undefined' where a stream was expected. You can provide an Observable, ...
Asool's user avatar
  • 14.3k
0 votes
3 answers
13k views

Error SEC7120: [CORS] The origin 'http://localhost:4200' did not find 'http://localhost:4200' in the Access-Control-Allow-Origin response

Actually I am trying to connect an Angular app with my Maven-Jersey-webapp(implements Rest Services concept) and getting this error. More Details: I am using Oracle10g XE Database Eclipse IDE for ...
Sanjeev Jangra's user avatar
-1 votes
1 answer
204 views

HTTP Response handling in angular 2 application

Working with angular 2 HTTP PUT request. I have a component and service. In the component I make request to update the attributes of account. It then calls the Service to update the account through ...
Nandini's user avatar
  • 31
0 votes
0 answers
450 views

Why is every API request creating a new session?

I am moving my project from AngularJS to Angular and it is creating a different session for each request; why? I have used withCredentials, this is user.service.ts: loginUser(username,password) { ...
priya_singh's user avatar
  • 2,488
1 vote
1 answer
4k views

Angular 2, v6: Write on assets/*.json file and save it [Typescript]

:) I have an Angular application (@angular/cli: ~6.0.3, typescript: ~2.7.2) which have a json file in assets folder. I'm trying to access this json file, write on it and save it. How can I do that? ...
psc37's user avatar
  • 81
0 votes
0 answers
7k views

500 Internal Server Error while making HTTP post request in typescript

I am building an angular2 app and I am pretty new at angular2. I am trying to make a post request but as an answer from the server, I got 500 INTERNAL SERVER ERROR and Response for preflight has ...
Nehil Danış's user avatar
0 votes
1 answer
427 views

how to access complex json object angular 2

//component.ts public items: any; getResult(){ var jsonBody = {}; jsonBody['activity'] = this.activity; jsonBody['seatnumber'] = this.seatNo; this.localService.postCall(jsonBody) ...
lakhan khandelwal's user avatar
2 votes
1 answer
1k views

angular-in-memory-web-api internal server error

I have reached the latest step in Angular's Tour-of-Heroes tutorial. After using the angular-in-memory-web-api, no data has appeared on my screen. There is no compilation error, but in the browser's ...
YTScorpion's user avatar
0 votes
1 answer
34 views

can get data out of http request

i have a problem receiving data to variable. this works: this.http.get(some_url).subscribe( data => { console.log(JSON.parse(data['_body'])) }); but if i try to get ...
AK96's user avatar
  • 1
1 vote
0 answers
2k views

Long running API request in Angular 5

I am using Angular 5! I am using HttpClient for every REST API request to my backend server. The issue I am facing currently is that a few API requests take longer to execute i.e approximately more ...
Nitish Kumar's user avatar
2 votes
1 answer
752 views

Notifying user when service returns, after routing to another component

I have a service that takes too long to return. Once the user has submitted a request, he/she should be able to navigate to any other page. How can I alert her that the request she submitted has ...
karthikaruna's user avatar
  • 3,276

15 30 50 per page
1
2 3 4 5
26