Custom Error and IIS Error Configuration

Anonymous
xml
09/29/2022 6:13 AM
804 B
15
Indexable
<system.web>
    <customErrors mode="Off" redirectMode="ResponseRewrite" defaultRedirect="~/500.html">
          <error statusCode="400" redirect="~/400" />
          <error statusCode="500" redirect="~/500.html" />
    </customErrors>
    
    <!-- IIS Error -->
    <httpErrors errorMode="Custom" existingResponse="Replace">
      <remove statusCode="404"/>
      <error statusCode="404" prefixLanguageFilePath="" path="/404" responseMode="ExecuteURL" />

      <remove statusCode="500"/>
      <error statusCode="500" path="500.html" responseMode="File"/>
    </httpErrors>
<system.web>
Editor is loading...