关于httpHandlers的问题
敌花师 2015-07-06 02:39:28 最近在做httpHandlers,资料例子各种试,还是404.大神帮忙看下我哪里出错了啊。
web.config里面在system.web中配置:
<httpHandlers>
<add verb="*" path="*.erp" type="WebApplication2.ERPHttpHandler,WebApplication2" />
</httpHandlers>
响应的handler信息如下:
using System;
using System.Collections.Generic;
using System.Web;
namespace WebApplication2
{
public class ERPHttpHandler:IHttpHandler
{
public void ProcessRequest(HttpContext context)
{
context.Response.Write("test erp");
}
public bool IsReusable
{
get { return false; }
}
}
}
HTTP 错误 404.0 - Not Found,我不要再看到这个啊