gpt4 book ai didi

asp.net-web-api2 - 找不到 ASP.NET web api 2 EnableCors 方法

转载 作者:行者123 更新时间:2023-12-04 23:44:49 24 4
gpt4 key购买 nike

我安装了 webapi2 并且程序集的版本安装成功并显示以下消息:

Adding 'Microsoft.AspNet.WebApi.Client 5.2.3' to AT.Web.
Successfully added 'Microsoft.AspNet.WebApi.Client 5.2.3' to AT.Web.
Adding 'Microsoft.AspNet.WebApi.Core 5.2.3' to AT.Web.
Successfully added 'Microsoft.AspNet.WebApi.Core 5.2.3' to AT.Web.
Adding 'Microsoft.AspNet.Cors 5.2.3' to AT.Web.
Successfully added 'Microsoft.AspNet.Cors 5.2.3' to AT.Web.

但是在注册方法中的 WebApiConfig.cs 中,想要启用 cors 但没有方法“EnableCors”,

请建议

最佳答案

关于asp.net-web-api2 - 找不到 ASP.NET web api 2 EnableCors 方法,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/31271916/

24 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com