如何从HttpModule获取当前请求的SPWebApplication?
答案 0 :(得分:1)
尝试自己构建SPSite
using(SPSite site = new SPSite(app.Context.Request.Url.ToString())) { //might need to trim the url
site.WebApplication
}
答案 1 :(得分:0)
尝试SPContext.Current.Site.WebApplication
?