Click here to Skip to main content
12,550,735 members (39,955 online)
Rate this:
Please Sign up or sign in to vote.
I published my new site to a test folder on my hosting with
Just to mention, I have another site build on the same hosting and it works fine.

After I publish the site I get this error:
The page cannot be displayed because an internal server error has occurred.

I disabled the web.config file and then I get this error on the hosting account.
Changed the name to Web.1config as a temporary move.

then this error comes up:
Runtime Error

Description: An application error occurred on the server. The current custom error settings for this application prevent the details of the application error from being viewed remotely (for security reasons). It could, however, be viewed by browsers running on the local server machine.

Details: To enable the details of this specific error message to be viewable on remote machines, please create a <customErrors> tag within a "web.config" configuration file located in the root directory of the current web application. This <customErrors> tag should then have its "mode" attribute set to "Off".
<!-- Web.Config Configuration File -->
        <customErrors mode="Off"/>
Notes: The current error page you are seeing can be replaced by a custom error page by modifying the "defaultRedirect" attribute of the application's <customErrors> configuration tag to point to a custom error page URL.

<!-- Web.Config Configuration File -->
        <customErrors mode="RemoteOnly" defaultRedirect="mycustompage.htm"/>

I have changed my web.config file in a few different ways and still no success.

        <customErrors mode="Off"/>
        <!--<customErrors mode="RemoteOnly" defaultRedirect=""/>-->
        <compilation debug="true" targetFramework="4.0">
I have remarked out the
<customErrors mode="Off"/>
and un-remarked the
<customErrors mode="RemoteOnly" defaultRedirect=""/>

I am completely stumped and not sure what to do.
Can anyone help me with this one... and let me know if you need any more information.
Thank you!

Thank you for your answers, and I have done all the changes that you guys have recommended with no success
Here is my complete web.config file:
<?xml version="1.0" encoding="utf-8"?>
        <add name="ApplicationServices" connectionString="data source=.\SQLEXPRESS;Integrated Security=SSPI;AttachDBFilename=|DataDirectory|\aspnetdb.mdf;User Instance=true" providerName="System.Data.SqlClient" />
        <customErrors mode="Off"/>
        <compilation debug="true" targetFramework="4.0">
                <add assembly="System.Web.Extensions.Design, Version=, Culture=neutral, PublicKeyToken=31BF3856AD364E35" />
                <add assembly="System.Design, Version=, Culture=neutral, PublicKeyToken=B03F5F7F11D50A3A" />
                <add assembly="System.Windows.Forms, Version=, Culture=neutral, PublicKeyToken=B77A5C561934E089" />
        <authentication mode="Forms">
            <forms loginUrl="~/Account/Login.aspx" timeout="2880" />
                <clear />
                <add name="AspNetSqlMembershipProvider" type="System.Web.Security.SqlMembershipProvider" connectionStringName="ApplicationServices" enablePasswordRetrieval="false" enablePasswordReset="true" requiresQuestionAndAnswer="false" requiresUniqueEmail="false" maxInvalidPasswordAttempts="5" minRequiredPasswordLength="6" minRequiredNonalphanumericCharacters="0" passwordAttemptWindow="10" applicationName="/" />
                <clear />
                <add name="AspNetSqlProfileProvider" type="System.Web.Profile.SqlProfileProvider" connectionStringName="ApplicationServices" applicationName="/" />
        <roleManager enabled="true">
                <clear />
                <add connectionStringName="ApplicationServices" applicationName="/"
                    name="AspNetSqlRoleProvider" type="System.Web.Security.SqlRoleProvider" />
                <add applicationName="/" name="AspNetWindowsTokenRoleProvider"
                    type="System.Web.Security.WindowsTokenRoleProvider" />
                <add tagPrefix="ajaxToolkit" assembly="AjaxControlToolkit" namespace="AjaxControlToolkit" />
        <httpErrors errorMode="Detailed" />
        <asp scriptErrorSentToBrowser="true"/>
        <!--<modules runAllManagedModulesForAllRequests="true" />
            <mimeMap fileExtension=".mp4" mimeType="video/mp4" />
            <mimeMap fileExtension=".m4v" mimeType="video/m4v" />
            <mimeMap fileExtension=".ogg" mimeType="video/ogg" />
            <mimeMap fileExtension=".ogv" mimeType="video/ogg" />
            <mimeMap fileExtension=".webm" mimeType="video/webm" />
            <mimeMap fileExtension=".oga" mimeType="audio/ogg" />
            <mimeMap fileExtension=".spx" mimeType="audio/ogg" />
            <mimeMap fileExtension=".svg" mimeType="image/svg+xml" />
            <mimeMap fileExtension=".svgz" mimeType="image/svg+xml" />
            <remove fileExtension=".eot" />
            <mimeMap fileExtension=".eot" mimeType="application/" />
            <mimeMap fileExtension=".otf" mimeType="font/otf" />
            <mimeMap fileExtension=".woff" mimeType="font/x-woff" />
            <remove fileExtension=".manifest" />
            <mimeMap fileExtension=".manifest" mimeType="text/cache-manifest" />
        <assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
                <assemblyIdentity name="AjaxControlToolkit" publicKeyToken="28f01b0e84b6d53e" culture="neutral" />
                <bindingRedirect oldVersion="" newVersion="4.1.60919.0" />

Does anyone have any ideas with this?
Posted 7-Jan-13 14:20pm
Updated 7-Jan-13 16:45pm
Christian Graus 7-Jan-13 20:23pm
Is there a web.config at a lower level that's overriding this one ? You're doing the right thing.
Ivan Perry 7-Jan-13 20:26pm
The only other web.config is in the Account folder(for logon and logoff), which I am not using at this time.
Christian Graus 7-Jan-13 20:51pm
Can't hurt to set that correctly, too. It might be getting picked up

1 solution

Rate this: bad
Please Sign up or sign in to vote.

Solution 1

According to this GoDaddy article, you need to do the following (rather than comment out the sections of the web.config you indicated in your question):
        <httpErrors errorMode="Detailed" />
        <asp scriptErrorSentToBrowser="true"/>
        <customErrors mode="Off"/>
        <compilation debug="true"/>
So, show detailed errors, enable scriptErrorSentToBrowser, disable custom errors, and set compilation to debug. Looks like you haven't tried modifying httpErrors errorMode, so maybe that was the missing piece. Also, I'm not sure which version of GoDaddy runs by default, so maybe mess with your attribute "targetFramework" on the "compilation" element. Keep in mind that if there is a problem with your web.config, won't be able to read it to determine that it should show error details.

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)

  Print Answers RSS
Top Experts
Last 24hrsThis month

Advertise | Privacy | Mobile
Web02 | 2.8.161021.1 | Last Updated 12 Feb 2015
Copyright © CodeProject, 1999-2016
All Rights Reserved. Terms of Service
Layout: fixed | fluid

CodeProject, 503-250 Ferrand Drive Toronto Ontario, M3C 3G8 Canada +1 416-849-8900 x 100