Saturday, March 22, 2014

system.web vs system.webserver

I have not worked in IIS6 and mostly I have worked on IIS 7+ and this came up when I was following a very old article (2003) ASP.Net article.

Anyway system.web is IIS6 and classic mode.
system.webserver is IIS7+  and integrated mode.

One scenario you might come across is when adding httpmodules to your ASP.Net project. If you want backward compatibility then you should add the module section to both system.web section (which is there by default for all ASP.Net projects ) and to system.webserver.

<system.web>
    <httpModules>
    </httpModules>
</system.web>

And

<system.webServer>
    <modules>
    </modules>
</system.webServer>


0 comments:

Post a Comment