Quantcast
Channel: All Forums
Viewing all articles
Browse latest Browse all 27852

why do i have to add in web.config?

$
0
0

Do I have to include the httpErrors in web.config if i want to have my own custom pages?

Hi: I am having something weird going on with my web app. I have a customError set in place already

<customErrors mode="On" redirectMode="ResponseRewrite"><error statusCode="404" redirect="~/errors/404.aspx" /></customErrors>

So right now, if i enter a bogus page, site/abcd.aspx, it will hit my customized error page, but if i enter an extensionless bad page, like site/wrongpage , it will hit the IIS default page.

We are using a CMS, so I configured that accordingly. But I am still seeing the problem.

Do I need to add the following in order for it to take care of the extensionless web pages as well?

<httpErrors><remove statusCode="404" subStatusCode="-1" /><error statusCode="404" prefixLanguageFilePath="" path="/errors/404.aspx" responseMode="ExecuteURL" /></httpErrors>

my co worker added that, and told me it is working OK now. But why? can someone explain to me why I need to add the ? I'd appreciate all your gurus help out there in advance.

Thanks.




Viewing all articles
Browse latest Browse all 27852

Trending Articles



<script src="https://jsc.adskeeper.com/r/s/rssing.com.1596347.js" async> </script>