[英]Delete verb not working in IIS 8 windows 2012 R2
Larvel website hosted on Windows server 2012 R2 but I am not able to delete Attachments in the website. Larvel网站托管在Windows Server 2012 R2上,但是我无法删除该网站中的附件。
Please refer screenshot now
Error message
Request URL:http://13.232.72.80/api/delete-form-data/form-field/33
Request method:DELETE
Remote address:13.232.72.80:80
Status code:
405
Version:HTTP/1.1
Referrer Policy:no-referrer-when-downgrade
Do you want to call asp.net web api with delete method? 您是否要使用Delete方法调用asp.net Web API?
If this is your requirement, I suggest you could try below solution to solve this issue. 如果这是您的要求,建议您尝试以下解决方案来解决此问题。
1.Open your IIS manager and locate the web sites and find the hanlder mapping. 1.打开您的IIS管理器,找到网站并找到hanlder映射。 Find ExtensionlessUrlHandler-Integrated-4.0, double click it. 找到ExtensionlessUrlHandler-Integrated-4.0,双击它。 Click Request Restrictions... button and on Verbs tab, add both DELETE. 单击“请求限制...”按钮,然后在“动词”选项卡上,添加两个DELETE。
2.Remove the WebDAVModule for your web application. 2.为您的Web应用程序删除WebDAVModule。
<system.webServer>
<modules>
<remove name="WebDAVModule" />
</modules>
<handlers>
<remove name="WebDAV" />
</handlers>
</system.webServer>
声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.