HEXAQ : A friendly question - answer site for IT professionals

500 internal server error when using ASPNET Captcha


0

I have uploaded my published project to hosting environment and started receiving 500 Internal server error.

I tried replacing my local web config file but no success.

This is my web.config file, can anyone check and help me to resolve the issue.

<?xml version="1.0"?>
<configuration>
  <configSections>
    <section name="dataConfiguration" type="Microsoft.Practices.EnterpriseLibrary.Data.Configuration.DatabaseSettings, Microsoft.Practices.EnterpriseLibrary.Data, Version=4.1.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35"/>
  </configSections>
  <dataConfiguration defaultDatabase="SPHOConnString">
    <providerMappings>
      <add databaseType="Microsoft.Practices.EnterpriseLibrary.Data.Sql.SqlDatabase, Microsoft.Practices.EnterpriseLibrary.Data, Version=4.1.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35" name="System.Data.SqlClient"/>
    </providerMappings>
  </dataConfiguration>
  <appSettings>
    <!--Website environment live / local-->
    <add key="EnvironmentType" value="live"/>
  </appSettings>
  <connectionStrings>
    <add name="SPHOConnString" connectionString="Data Source=sampleserver;Initial Catalog=sampledb;User ID=sampleuser;Password=samplepassword;Integrated Security=False" providerName="System.Data.SqlClient"/>
  </connectionStrings>
  <system.web>
    <!-- 
            Set compilation debug="true" to insert debugging 
            symbols into the compiled page. Because this 
            affects performance, set this value to true only 
            during development.
        -->
    <compilation debug="true" targetFramework="4.0">
      <assemblies>
        <add assembly="System.Design, Version=4.0.0.0, Culture=neutral, PublicKeyToken=B03F5F7F11D50A3A"/>
        <add assembly="System.Web.Extensions.Design, Version=4.0.0.0, Culture=neutral, PublicKeyToken=31BF3856AD364E35"/>
        <add assembly="System.Windows.Forms, Version=4.0.0.0, Culture=neutral, PublicKeyToken=B77A5C561934E089"/>
      </assemblies>
    </compilation>
    <httpRuntime requestValidationMode="2.0"/>
    <!--
            The <authentication> section enables configuration 
            of the security authentication mode used by 
            ASP.NET to identify an incoming user. 
        -->
    <authentication mode="Forms"/>
    <!--
            The <customErrors> section enables configuration 
            of what to do if/when an unhandled error occurs 
            during the execution of a request. Specifically, 
            it enables developers to configure html error pages 
            to be displayed in place of a error stack trace.

        <customErrors mode="RemoteOnly" defaultRedirect="GenericErrorPage.htm">
            <error statusCode="403" redirect="NoAccess.htm" />
            <error statusCode="404" redirect="FileNotFound.htm" />
        </customErrors>
        -->
    <customErrors mode="Off"/>
    <pages controlRenderingCompatibilityVersion="3.5" clientIDMode="AutoID" validateRequest="false">
      <controls>
        <add tagPrefix="cc" assembly="AjaxControlToolkit" namespace="AjaxControlToolkit.HTMLEditor" />
      </controls>
    </pages>
    <trust level="Full"/>

  </system.web>
  <!-- 
        The system.webServer section is required for running ASP.NET AJAX under Internet
        Information Services 7.0.  It is not necessary for previous version of IIS.
    -->
  <system.webServer>
      <modules runAllManagedModulesForAllRequests="true">
      <remove name="UrlRoutingModule"/>
      <add name="UrlRoutingModule" type="System.Web.Routing.UrlRoutingModule, System.Web, Version=4.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a" />
    </modules>
    <handlers>
      <add name="UrlRoutingHandler" preCondition="integratedMode" verb="*" path="UrlRouting.axd" type="System.Web.HttpForbiddenHandler, System.Web,&#xD;&#xA;Version=2.0.0.0, Culture=neutral,&#xD;&#xA;PublicKeyToken=b03f5f7f11d50a3a"/>
        <add verb="GET" path="Image.ashx" type="ASPNET_Captcha.Image, ASPNET_Captcha" />
    </handlers>
    <security>
      <requestFiltering allowDoubleEscaping="true"></requestFiltering>
    </security>
  </system.webServer>
</configuration>
Â
asked
 


≡ Total 0 Answer

Enter your reply here
Answer Preview:
Viewed: 817 times
Asked on: 7/9/2014
Permalink
Topics in this question
  7
  1
  1
  1
  1
Search Question
Similler Questions