Answers for "how to enable cors in asp.net web api"

C#
0

how to enable cors policy in web api

BY LOVE
To enable CORS policy in web api, You need to add this method in your Global.asax file of API project. i.e
        
        protected void Application_BeginRequest()
        {
            HttpContext.Current.Response.AddHeader("Access-Control-Allow-Origin", "*");
        }
Posted by: Guest on July-04-2020
0

enable cors asp.net mvc

Response.AppendHeader("Access-Control-Allow-Origin", "*");
Posted by: Guest on October-04-2020

Code answers related to "how to enable cors in asp.net web api"

C# Answers by Framework

Browse Popular Code Answers by Language