Ravi Kumar
What is the difference between web.config and machine.config ?
By Ravi Kumar in ASP.NET on Nov 14 2006
  • f k
    Sep, 2009 7

    changes in machine.config are applied to all applications running on that m/c while web.config used for particular web application

    • 0
  • Divya Parashar
    Nov, 2006 15

    The ASP.NET Web.config file is used to define the configuration settings for an ASP.NET application. ASP.NET and the .NET Framework use .config files to define all configuration options. The .config files, including the ASP.NET Web.config file, are XML files. The ASP.NET application configuration settings can be changed by creating a file called Web.config and saving it in the root folder of the application.This is how the minimal Web.config file should look like:





    The first line of the Web.config file is the same as the first line for any .config file and specifies that this is an XML document with utf-8 character encoding type.
    There are 2 important characteristics of the Web.config file. The first one is that if you change your Web.config file, you don?t need to re-compile your ASP.NET application.
    The second one is that the Web.config file cannot be viewed in directly in a browser.

    Server-wide configuration settings for the .NET Framework are defined in a file called Machine.config. The settings in the Machine.config file can be changed and those settings affect all .NET applications on the server.what if the Machine.config file defines different settings than the ones defined in your Web.config file? The  settings in the Web.config file override the settings in the Machine.config file.

    • 0


Most Popular Job Functions


MOST LIKED QUESTIONS