是否有任何"好的"方法通过使用WebConfigurationManager来读取IIS7的配置节组?我试图读取授权部分,但WebConfigurationManager.GetSection()返回一个'IgnoredSection'实例.这就是我的代码看起来像......
authSection = WebConfigurationManager.GetSection("system.webServer/security/authorization", HttpContext.Current.Request.Path)
Run Code Online (Sandbox Code Playgroud)