Question

So I had to change all the links on a certain site, so I put in a PageNotFound page.

I setup web.config to redirect 404 errors to this PageNotFound page.

After going live, the PageNotFound page was the most visited page, something like 5000+.

I later determined that this was the issue: Why is @font-face throwing a 404 error on woff files?

Basically font-face was throwing 4 404 errors on every page.

My question is this, would the PageNotFound page be hit that way? Because I was never redirected to the 404 page, but it was registering as the highest hit page until I fixed the font-face issue.

Was it helpful?

Solution

Like horatio says, for asp.net a page is just another resource! it doesn't matter whether its a page (.aspx), image, css or whatever document. As long its in the asp.net pipeline (which EVERY request is per default on IIS 7) an 404 statuscode would show your page defined under customErrors in web.config

OTHER TIPS

You ask if it would and obviously, "yes," since it happened to you. If you were to attempt to load the resource by typing in the url you would probably receive the redirected 404 response page you set up.

Note that 404 is not "page not found," but rather "resource not found"

404 The requested resource could not be found but may be available again in the future. Subsequent requests by the client are permissible

Licensed under: CC-BY-SA with attribution
Not affiliated with StackOverflow
scroll top