Base solution for your next web application
Ends in:
01 DAYS
01 HRS
01 MIN
01 SEC
Open Closed

Access Control Origin Angular 2 #2560


User avatar
0
cangunaydin created

Hello i have deployed my application to a test server. Angular and .Net Core Projects are working fine. But when i open the login page from angular app it gives me access control origin error.

Response to preflight request doesn't pass access control check: No 'Access-Control-Allow-Origin' header is present on the requested resource

But when i call the same link from my web browser i am getting a response. My ui application runs from another port. What can i do to fix the problem. Any solution that you can suggest?


1 Answer(s)
  • User Avatar
    0
    cangunaydin created

    Nevermind. i forget to change the url in WebSiteRootAddress branch of appsettings.json. Now it is working fine.