Asp.net core appConfig无法识别的配置节system.webServer
你好。 我在设置app.config时遇到问题 当我尝试从appConfig访问PayPal节点时,问题开始出现。Asp.net core appConfig无法识别的配置节system.webServer,asp.net-core,.net-core,paypal,Asp.net Core,.net Core,Paypal,你好。 我在设置app.config时遇到问题 当我尝试从appConfig访问PayPal节点时,问题开始出现。 我遇到了以下错误“无法识别的配置部分system.webServer” 如果您使用的是ASP.NET Core,那么为什么要在yoru web.config中嵌入Paypal配置?ASP.NET核心是通过appsettings.json文件配置的。ASP.NET核心站点的web.config中唯一需要的配置是特定于IIS的。如果您的问题是关于ASP.NET核心的,请使用ASP.N
我遇到了以下错误“无法识别的配置部分system.webServer”
如果您使用的是ASP.NET Core,那么为什么要在yoru web.config中嵌入Paypal配置?ASP.NET核心是通过appsettings.json文件配置的。ASP.NET核心站点的web.config中唯一需要的配置是特定于IIS的。如果您的问题是关于ASP.NET核心的,请使用ASP.NET核心
标记,而不是ASP.NET
,这是一个不同的框架。好的,让我尝试移动它。我不确定这是你当前错误的根源…我注意到的一些问题需要解决。你的想法非常有效!!非常感谢!!
<?xml version="1.0" encoding="utf-8"?>
<configuration>
<system.webServer>
<handlers>
<remove name="aspNetCore"/>
<add name="aspNetCore" path="*" verb="*" modules="AspNetCoreModule" resourceType="Unspecified"/>
</handlers>
<aspNetCore processPath="%LAUNCHER_PATH%" arguments="%LAUNCHER_ARGS%" stdoutLogEnabled="false" stdoutLogFile=".\logs\stdout" />
<security>
<requestFiltering>
<!-- This will handle requests up to 100MB -->
<requestLimits maxAllowedContentLength="102400" />
</requestFiltering>
</security>
</system.webServer>
<configSections>
<section name="paypal" type="PayPal.SDKConfigHandler, PayPal" />
</configSections>
<paypal>
<settings>
<add name="mode" value="sandbox"/>
<add name="clientId" value="xxx"/>
<add name="clientSecret" value="xxx"/>
</settings>
</paypal>
</configuration>