📄 usermappath.cs
字号:
using System;
using System.Web;
public class UserMapPath : IHttpModule {
public String ModuleName {
get {
return "UserMapPath";
}
}
public void Init(HttpApplication app) {
app.BeginRequest += new EventHandler(this.App_BeginRequest);
}
public void App_BeginRequest(Object sender, EventArgs e) {
HttpApplication application = (HttpApplication) sender;
HttpContext context = application.Context;
HttpRequest Request = context.Request;
String path = Request.Path;
int index = path.IndexOf("~");
if (index > 0) {
String newPath = path.Substring(0, (index - 1));
String name = path.Substring(index);
context.Response.Write(newPath + " : " + name);
}
}
public void Dispose() {
}
}
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -