【发布时间】:2015-11-03 16:39:57
【问题描述】:
我正在尝试在我的 ASP.NET Core Web API 上启用跨源资源共享,但我卡住了。
EnableCors 属性接受 policyName 类型的 string 作为参数:
// Summary:
// Creates a new instance of the Microsoft.AspNetCore.Cors.Core.EnableCorsAttribute.
//
// Parameters:
// policyName:
// The name of the policy to be applied.
public EnableCorsAttribute(string policyName);
policyName 是什么意思?如何在 ASP.NET Core Web API 上配置 CORS?
【问题讨论】:
标签: c# asp.net-core