PDA

View Full Version : Two Web Applications and web.config issue


stephen2d
05-04-2009, 02:33 AM
Hello. Just moved from another host and I have tried to test my site before updating DNS records.

I seem to have an issue here that my "Forum" application, which I have set as a separate web app, is still using the web.config from the root folder.

The error I get is:
Configuration Error body {font-family:"Verdana";font-weight:normal;font-size: .7em;color:black;} p {font-family:"Verdana";font-weight:normal;color:black;margin-top: -5px} b {font-family:"Verdana";font-weight:bold;color:black;margin-top: -5px} H1 { font-family:"Verdana";font-weight:normal;font-size:18pt;color:red } H2 { font-family:"Verdana";font-weight:normal;font-size:14pt;color:maroon } pre {font-family:"Lucida Console";font-size: .9em} .marker {font-weight: bold; color: black;text-decoration: none;} .version {color: gray;} .error {margin-bottom: 10px;} .expandable { text-decoration:underline; font-weight:bold; color:navy; cursor:hand; } Server Error in '/forum' Application.

Configuration Error

Description: An error occurred during the processing of a configuration file required to service this request. Please review the specific error details below and modify your configuration file appropriately.

Parser Error Message: Could not load file or assembly 'FreeTextBox' or one of its dependencies. The system cannot find the file specified.

Source Error:

Line 26: Line 27: <httpHandlers> Line 28: <add verb="GET" path="FtbWebResource.axd" type="FreeTextBoxControls.AssemblyResourceHandler, FreeTextBox" /> Line 29: </httpHandlers> Line 30: <identity impersonate="true" />
Source File: E:\web\**myusername**\htdocs\web.config Line: 28

Assembly Load Trace: The following information can be helpful to determine why the assembly 'FreeTextBox' could not be loaded.

WRN: Assembly binding logging is turned OFF. To enable assembly bind failure logging, set the registry value [HKLM\Software\Microsoft\Fusion!EnableLog] (DWORD) to 1. Note: There is some performance penalty associated with assembly bind failure logging. To turn this feature off, remove the registry value [HKLM\Software\Microsoft\Fusion!EnableLog].
I am not using the Freetextbox in Forum, which is another web app, and this is not the relevant web.config file.

Have I forgotten to do something obvious here? BTW, as usual is a response, it all works fine on my dev machine and on the other host's server.

CrystalCMS
05-04-2009, 03:47 AM
The root web.config is being inherited by the sub web application. This behaviour can be prevented by adding <location path="." inheritInChildApplications="false"> to your root web.config

See this post for a further explanation:http://community.discountasp.net/showthread.php?p=29962#post29962

stephen2d
05-09-2009, 09:11 PM
Thanks CrystalCMS. That was exactly it.