1

So I have an existing angular 7 web application (let's call this myapp) which runs on IIS (App Service) hosted in Azure.

There is a legacy application (let's call this theirapp), with it's own embedded browser, which will load our application by navigating to myapp's url.

When theirapp loads myapp, theirapp passes some information in the header something like Request.headers.SpecificThingMyAppNeeds

I need to be able to access this request.headers in myapp.

Thank you all!

jmesolomon
  • 563
  • 5
  • 15
  • Duplicate of https://stackoverflow.com/questions/48184107/read-response-headers-from-api-response-angular-5-typescript/48184742 – Karthick Manoharan Oct 07 '19 at 05:04
  • Hi @Karthick, i dont think it's a duplicate. myapp doesn't make the request. it gets loaded from a browser – jmesolomon Oct 07 '19 at 07:01
  • What do you mean by gets loaded from browser? – Karthick Manoharan Oct 07 '19 at 07:23
  • @KarthickManoharan Client1 has a winform application with an embedded IE11. Client1 launches their embedded IE11 to browse my webapp via https://myapp.com. Client1's browser sends extra information in the header when it browses myapp. – jmesolomon Oct 08 '19 at 20:44
  • @jmesolomon Your Application is running in the browser, so your application doesn't receive any requests, but the browser does. you could refer this link: https://stackoverflow.com/questions/51984914/how-to-get-request-header-value-when-accessing-my-angular-application – Jalpa Panchal Oct 10 '19 at 09:35
  • @JalpaPanchal thanks! you are correct. I think the solution is to change our architecture. Regards – jmesolomon Oct 11 '19 at 03:18
  • @jmesolomon if my solution helps you then I request you to mark the post as an answer it will help other people. thank you for understanding. – Jalpa Panchal Oct 11 '19 at 03:21

1 Answers1

1

Your application is running in the browser, so your application doesn't receive any requests, but the browser does. you could refer this link

Jalpa Panchal
  • 8,251
  • 1
  • 11
  • 26