我已经到处搜索并尝试了所有解决方案,但似乎没有什么对我有用。上传大于 64k 的图像时,我收到错误的 400 请求。它正在工作,然后突然停止工作。也无需更改代码或更改配置文件。还有什么可能影响配置文件设置?这是我的配置文件
<system.web>
<customErrors mode="Off"/>
<compilation debug="true" targetFramework="4.0" />
<httpRuntime maxRequestLength="2147483647"/>
</system.web>
<system.serviceModel>
<services>
<service behaviorConfiguration="webHttpBehavior" name="EzFindWCFService.EZFindWebService">
<endpoint address="" behaviorConfiguration="EzFindWCFService.EZFindWebServiceAspNetAjaxBehavior"
binding="webHttpBinding" contract="EzFindWCFService.EZFindWebService" />
</service>
</services>
<behaviors>
<endpointBehaviors>
<behavior name="EzFindWCFService.EZFindWebServiceAspNetAjaxBehavior">
<!--<enableWebScript />-->
<webHttp/>
</behavior>
</endpointBehaviors>
<serviceBehaviors>
<behavior name="webHttpBehavior">
<serviceMetadata httpGetEnabled="true" />
<serviceDebug includeExceptionDetailInFaults="true" />
<dataContractSerializer maxItemsInObjectGraph="2147483647" />
</behavior>
</serviceBehaviors>
</behaviors>
<serviceHostingEnvironment aspNetCompatibilityEnabled="true"
multipleSiteBindingsEnabled="true" />
<bindings>
<basicHttpBinding>
<binding name="webHttpBinding" closeTimeout="00:10:00" openTimeout="00:10:00"
receiveTimeout="00:10:00" sendTimeout="00:05:00" allowCookies="false"
bypassProxyOnLocal="false" hostNameComparisonMode="StrongWildcard"
maxBufferSize="2147483647" maxBufferPoolSize="2147483647" maxReceivedMessageSize="2147483647"
messageEncoding="Text" textEncoding="utf-8" transferMode="Buffered"
useDefaultWebProxy="true">
<readerQuotas maxDepth="64" maxStringContentLength="2147483647"
maxArrayLength="2147483647" maxBytesPerRead="2147483647" maxNameTableCharCount="2147483647" />
<security mode="None">
<transport clientCredentialType="None" proxyCredentialType="None"
realm="" />
<message clientCredentialType="UserName" algorithmSuite="Default" />
</security>
</binding>
</basicHttpBinding>
</bindings>
</system.serviceModel>