Is it OK to use the custom 404 page in IIS to make a seo-friendly URL? Ie. thisdomain.com/display.asp?a=1&b=2&c=3 could become: thisdomain.com/men/coats/ben-sherman-jacket-p-154.html
You should be doing this anyway, and not for your 404 page. The 404 is delivered if the page or file cannot be found. The link won't matter if it's www.example.com/pid=54864143 or www.example.com/oops/ - it'll still get the same 404 error message sent to the user. What you want to do is make that 404 error as user friendly as possible. Something like this, for example:
What I want to do is use the 404 error handler to return the correct page by examining the URL entered. Will the server response be correct or will Google detect that the page is being handled by the 404 handler?
What do you mean by "return the correct page"? What if "the correct page" doesn't even exist? What would you do then? The best you can do is use a template like the one I posted earlier and use an HTTP referrer to inform Google and the other search engines that the page or file doesn't exist so they can remove it from their indexes (if the page was deleted) or not even try to crawl it in the first place. If the page was MOVED (such as the page was renamed) then a 301 redirect would be the proper HTTP referrer to use.
Actually, I'm pretty sure I do. If I read your posts correctly, you want to rewrite a 404 URL simply cannot be done (but it can be faked). To make a long story short, the link that a person types in is the link that will be used in your server's error logs (and shown in the browser's address bar) - there's no way around it unless you redirect the user to a specific 404 error page, like so: I go to www.example.com/blahblahblahblah.html The server tries to access the file but can't find anything. It then sends a 404 error, which gets forwarded via a 301 redirect (actually a 302 redirect might be better here) to www.example.com/error-page/ The custom error page tells the user that the page or file couldn't be found. This isn't the 404 at work here. It involves using a 301 (or 302) redirect to point the user to a specific error page which happens to have an SEO friendly URL.
What does google think about 301 or 302 redirects. Are there any web tools I can use to check what headers are being sent?
They're perfectly acceptable to Google if used properly. Just don't try stuffing any keywords in the rewritten URLs if you're using them to forward someone to an error page.
There are url rewriting engines for IIS. http://www.isapirewrite.com/ http://www.qwerksoft.com/products/iisrewrite/ There might be some other ones too.
Can I make the error 404 page stream the correct page as if the old (or non-existant) page is valid? I can't install any server-side software as I'm on a shared host.