[整理]IIS 6.0 下部署 Asp.net MVC Web Api 后 HTTP PUT and DELETE 请求失败
http://guodong.me/?p=1560
ASP.NET MVC 4 has a new feature called WebAPI which makes it much easier to create a REST API in ASP.NET. Unfortunately, I ran into one problem with IIS 6.0 that prevented the full REST spec from being used. By default IIS 6 wouldn’t allow the PUT or DELETE verbs to be used with the WebAPI app that we created.
Page requests using GET and POST worked fine, but PUT and DELETE gave the following error:
Failed to load resource: the server responded with a status of 501 (Not Implemented)
In order to solve the issue I needed to add the ASP.NET 4.0 dll to
the Wildcard mappings in the Configuration area on the Home Directory
tab for the website. That fixed the problem for me. Here are the steps
that I took to correct the issue in IIS.
1. Find the web site in the “Web Sites” folder in Internet Information Services (IIS) and right-click and select properties.
![]()
2. Go to the “Home Directory” tab and click the “Configuration…” button.
![]()
3. Find the .aspx extension in the “Application extensions” table, select it and press the “Edit…” button.
![]()
4. Copy the entire path and file name in the “Executable:” text box to the clipboard. Press the “Cancel” button.
![]()
5. Press the “Insert…” button near the “Wildcard application maps”
list box. Paste the text from the clipboard into the “Executable:” text
box and press “OK”.
![]()
6. Press OK on the Application Configuration dialog and again on the website properties box.
参考:
http://stackoverflow.com/questions/9904897/iisnode-iis7-5-405-method-not-allowed-when-performing-put-request
http://www.cnblogs.com/artech/p/3606873.html
http://www.cnblogs.com/artech/p/web-api-sample.html
http://blog.csdn.net/forgotaboutgirl/article/details/6936982
[整理]IIS 6.0 下部署 Asp.net MVC Web Api 后 HTTP PUT and DELETE 请求失败的更多相关文章
- 主攻ASP.NET MVC4.0之重生:ASP.NET MVC Web API
UserController代码: using GignSoft.Models; using System; using System.Collections.Generic; using Syste ...
- 在Mac下创建ASP.NET Core Web API
在Mac下创建ASP.NET Core Web API 这系列文章是参考了.NET Core文档和源码,可能有人要问,直接看官方的英文文档不就可以了吗,为什么还要写这些文章呢? 原因如下: 官方文档涉 ...
- [译]ABP框架使用AngularJs,ASP.NET MVC,Web API和EntityFramework构建N层架构的SPA应用程序
本文转自:http://www.skcode.cn/archives/281 本文演示ABP框架如何使用AngularJs,ASP.NET MVC,Web API 和EntityFramework构建 ...
- ASP.NET MVC Web API 学习笔记---第一个Web API程序
http://www.cnblogs.com/qingyuan/archive/2012/10/12/2720824.html GetListAll /api/Contact GetListBySex ...
- ABP 教程文档 1-1 手把手引进门之 AngularJs, ASP.NET MVC, Web API 和 EntityFramework(官方教程翻译版 版本3.2.5)含学习资料
本文是ABP官方文档翻译版,翻译基于 3.2.5 版本 转载请注明出处:http://www.cnblogs.com/yabu007/ 谢谢 官方文档分四部分 一. 教程文档 二.ABP 框架 三. ...
- ASP.NET MVC Web API Post FromBody(Web API 如何正确 Post)
问题场景: ASP.NET MVC Web API 定义 Post 方法,HttpClient 使用 JsonConvert.SerializeObject 传参进行调用,比如 Web Api 中定义 ...
- ASP.NET MVC Web API For APP
近来很多大型的平台都公开了Web API.比如百度地图 Web API,做过地图相关的人都熟悉.公开服务这种方式可以使它易于与各种各样的设备和客户端平台集成功能,以及通过在浏览器中使用 JavaScr ...
- 【转载】ASP.NET MVC Web API 学习笔记---联系人增删改查
本章节简单介绍一下使用ASP.NET MVC Web API 做增删改查.目前很多Http服务还是通过REST或者类似RESP的模型来进行数据操作的.下面我们通过创建一个简单的Web API来管理联系 ...
- Asp.net mvc web api 在项目中的实际应用
Asp.net mvc web api 在项目中的实际应用 前言:以下只是记录本人在项目中的应用,而web api在数据传输方面有多种实现方式,具体可根据实际情况而定! 1:数据传输前的加密,以下用到 ...
随机推荐
- 线状地物图斑化全流程作业(使用ArcMap软件)
一.线状地物调整 1.添加全覆盖图斑数据 2.添加线状地物 3.添加地理图斑 4.添加村界 5.剪裁自己村界的线状地物得(地理处理/剪裁(输入要素为线状地物,剪裁要素为村界,输出要素是得到的新层位置) ...
- 英特尔帮助优化 Epic 的《堡垒之夜》* 和 Unreal Engine*
您可能知道,Epic 的游戏<堡垒之夜>是 Unreal Engine* 技术的绝佳示例,<堡垒之夜>的开发团队正不断改进游戏,增加支持平台的数量并将信息反馈给引擎.为此,英特 ...
- Jenkins邮件通知
Jenkins邮件通知 Jenkins 配备了一个开箱工具,添加一个电子邮件通知的构建项目. 第1步 - 配置SMTP服务器. 转到 Manage Jenkins → Configure System ...
- Final发布——视频博客
1.视频链接 视频上传至优酷自频道,地址链接:http://v.youku.com/v_show/id_XMzk1OTIwNTUwMA==.html?spm=a2h0j.11185381.listit ...
- M1事后分析报告--We have power to change the origin state
M1事后分析报告 设计与实现 我们发的软件解决的问题?是否满足后面小组的要求?是否能够完全拟合前期目标? 答: 前期我们的软件完成量并不是特别让人满意,我们组在完成这些任务量之后,发现有很多地方是在做 ...
- 小学四则运算APP 第一阶段冲刺 第二天-补
团队成员:陈淑筠.杨家安.陈曦 团队选题:小学四则运算APP 第一次冲刺阶段时间:11.17~11.27 本次发布已经解决上次问题,问题是写程序逻辑错误,问题已经修改!我们还增加两个模块的面板设置,如 ...
- Daily Scrum & Project Team Meeting Review - 11/27
Welcome back Liyuan! Project Team Meeting Review 今天很荣幸能和Xin Zou.Travis Li.Ran Bi和Zhongqiu交流了项目进度和下一步 ...
- Beat版本冲刺(七)
目录 组员情况 组员1:胡绪佩 组员2:胡青元 组员3:庄卉 组员4:家灿 组员5:恺琳 组员6:翟丹丹 组员7:何家伟 组员8:政演 组员9:黄鸿杰 组员10:何宇恒 组员11:刘一好 展示组内最新 ...
- 蜗牛慢慢爬 LeetCode 16. 3Sum Closest [Difficulty: Medium]
题目 Given an array S of n integers, find three integers in S such that the sum is closest to a given ...
- html+css照片墙
html文件 <!DOCTYPE html><html lang="en"><head> <meta charset="UTF- ...