Reputation: 1800
I am trying to add a custom httpmodule to the httpModules section of a web.config in a rather large .NET app.
The module did not seem to actually be getting hit after I added it.
On a whim, I changed one of the default modules to be wrong to see what happens:
This:
<add name="ScriptModule" type="System.Web.Handlers.ScriptModule, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
Became this:
<add name="ScriptModule" type="Blah.Blah.Blah, System.Web.Extensions, Version=3.5.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
The app still works! It compiles and runs fine...somehow. If I create a new web app from scratch and make the same change it breaks as expected.
How is this possible? I am absolutely positive that it is the right web.config. If I purposely break other parts of it(or change the tag to even) the app throws an error like it should.
Upvotes: 2
Views: 793
Reputation: 1800
http://www.byteblocks.com/post/2010/09/16/HttpModule-Not-Working-In-IIS7.aspx
Upvotes: 4