Generic HTTP Error 404.0 - Not Found Page Loading

Discussion in 'ASP.NET / ASP.NET Core' started by Will1968, Jul 19, 2010.

Thread Status:
Threads that have been inactive for 5 years or longer are closed to further replies. Please start a new thread.
  1. Hi,

    Google Webmaster states that my website has a crawl error.

    When I click on the link it trys to load this URL (even though it looks like its going to try and load this http://www.curtainsmadesimple.co.uk/default.aspx?id=1300)...
    http://www.curtainsmadesimple.co.uk/default.aspx?id=1300

    Ok I realise the URL is a load of rubbish but I expected the custom 404 error page to open.

    I have custom errors set up on my web.config file. So I am a little surprised I get the page that loads with this url...

    http://www.curtainsmadesimple.co.uk/default.aspx?id=1300

    <customErrors mode="On" defaultRedirect="~/Errors/Error.aspx">
    <error statusCode="401" redirect="~/Errors/401-Not-Logged-In.aspx"/>
    <error statusCode="403" redirect="~/Errors/403-Not-Authorised.aspx"/>
    <error statusCode="404" redirect="~/Errors/404-Page-Not-Found.aspx"/>
    <error statusCode="500" redirect="~/Errors/500-Server-Error.aspx"/>
    </customErrors>

    Kind regards,

    Will
     
  2. Bruce

    Bruce DiscountASP.NET Staff

    What you posted is asp.net custom error. You also have to set the IIS custom error.

    You can do so in the IIS Manager (which will put something in your web.config)
     
  3. I used IIS Tools -> Custom Errors tab from DASP panel so I like this custom 404
    But I can't do this on my machine :confused:
     
  4. mjp

    mjp

    What do you mean by your machine?
     
  5. my development computer station
     
  6. Resolved!

    I resolved this problem by adding /EasyWebReports/ to 404 url because my web app is not on Default dir.
     
  7. Do you mean here?...

    Apologies for not responding earlier, forgot to set email notification.

    I just want to check that I have set the custom error properly.

    I opened IIS Manager and navigated as follows....
    IIS Manager Home -> .Net Error Pages

    Then went to the actions menu on the right and clicked on "Edit Error Pages" Settings

    Then set Mode to Remote or On?

    Have I done what you asked correctly, Bruce?

    Thanks,

    Will
     
Thread Status:
Threads that have been inactive for 5 years or longer are closed to further replies. Please start a new thread.

Share This Page