Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Is the ASP.NET web.config file getting out of hand?

Heres something I've been pondering for a while ...

Do you struggle with the size and the number of entries in the web.config file? Do you understand every element?

Is it time for Microsoft to relook at how an ASP.NET site is configured, perhaps by splitting the web.config file into multiple files?

like image 907
James Westgate Avatar asked Apr 08 '10 13:04

James Westgate


People also ask

Where is the ASP.NET configuration file?

The Machine. config file is located in the %SystemRoot%\Microsoft.NET\Framework\%VersionNumber%\CONFIG\ directory.

Does .NET core still use Web config?

ASP.NET Core no longer uses the Global. asax and web. config files that previous versions of ASP.NET utilized.

Where is Web config file in Visual Studio 2022?

config file is located in the %SystemRoot%\Microsoft.NET\Framework\%VersionNumber%\CONFIG\ folder. The default settings that are contained in the Machine.

Where is my Web config file located?

The Web. Config file is used to configure Oracle Web Application functionality. This file is typically installed in the c:\Inetput\wwwroot\WebApp directory.


2 Answers

They did.

In ASP.Net 4.0, all of the standard Web.config entries for ASP.Net AJAX sites are in Machine.config, allowing new Web projects to start with an (almost) empty Web.config.

In addition, VS2010 allows you to combine multiple web.config files during a build.

like image 161
SLaks Avatar answered Nov 03 '22 00:11

SLaks


Man I HATE the web.config file - it's a complete mess. As the previous answerer mentioned, this has been trimmed and tidied up in ASP.NET 4.

However, for those of us stuck with earlier tech (e.g. ASP.NET3.5, VS2008 etc.), you can still split it up into multiple files to make it more manageable by using the configSource attribute.

See this article

like image 23
UpTheCreek Avatar answered Nov 03 '22 02:11

UpTheCreek