Re: Strange test results on IIS6 when 404 set to custom ASP redirect
From: Boris Elster (boris.elster_at_geac.com)
Date: 10/14/04
- Next message: Paul: "Service(Default Web Site)\Current Connections limited to 35?"
- Previous message: Consultant: "Re: Remove FTP Login Prompt"
- In reply to: Ken Schaefer: "Re: Strange test results on IIS6 when 404 set to custom ASP redirect"
- Next in thread: Ken Schaefer: "Re: Strange test results on IIS6 when 404 set to custom ASP redirect"
- Reply: Ken Schaefer: "Re: Strange test results on IIS6 when 404 set to custom ASP redirect"
- Messages sorted by: [ date ] [ thread ]
Date: 14 Oct 2004 07:36:56 -0700
I've tried keeping things simple and include only (what I thought was)
the relevant details. Let me make this into a longer posting and give
you as many details as I can.
The environment is W2K3, IIS6. There are multiple web sites set up
under one IP, e.g.,
www.abc.domain.com
www.xyz.domain.com
www.nnn.domain.com
The custom 404 I want displayed for all sites is located at
www.abc.domain.com/sitemap/default.asp (from here on, my404). When
someone tries to access www.xyz.domain.com/nonexistent/url, I want
my404 to come up. In IIS, when the default 404 file is changed to
URL, IIS will only accept relative (not absolute) paths. For this
reason, each site has a 404.asp in its root and the custom 404 for
each site is URL with value "/404.asp". The code of this ASP is
<%response.redirect(my404)%>
Now, back to the link checker. When a page is analyzed for broken
links, there's a GET my404 call for each object referenced by said
page (see original posting for details – though, do notice I use
different URLs here). This happens _only_ in the case of sites that
have a 404 set up as a _redirect_. When the 404 is the IIS default,
or is some static HTML file, or is an ASP script that _does not_ do a
redirect, the link checker test does not show any GET my404 calls.
To test this behaviour, I used 2 sites: 1 with a 404.asp that used
response.redirect; 1 with a 404.asp that used response.write. I set
up a simple HTML page with 2 images and put all 3 files in a "/test"
folder in the root of each site. (Let's be clear on one thing: There
should be no 404s thrown by the server. When viewed in a browser, the
test page under each of the two URLs rendered fine – i.e. both images
were displayed.)
The link checker test results were the same as previous: GET my404
requests for each image when 404.asp set up as a response.redirect; no
GET my404 requests when 404.asp set up as a response.write.
Earlier, you wrote: "[...] your website is throwing 404 errors."
Exactly. I already know that, hence this posting in the first place.
My original question stands. Why am I getting these GET my404 calls
for every object referenced by my page _only_ when the page is running
off of a site whose custom 404 does a response.redirect – keeping in
mind that a) the page renders fine in a browser and b) all objects
have been verified to exist as referenced?
Hope this is enough information. If not, you will need to ask
specific questions for I don't know what more I can say.
Boris
P.S. Even if there is a way to give IIS an absolute URL for a custom
404, this will only be an alternative for handling 404s in the future
(i.e. I may consider it in the future), but will still leave
unexplained the weird behaviour I'm seeing under my current setup.
"Ken Schaefer" <kenREMOVE@THISadOpenStatic.com> wrote in message news:<euNLRtNsEHA.1032@TK2MSFTNGP10.phx.gbl>...
> I really wish I knew what you were talking about.
>
> IIS can redirect a request to an existing resource to an absolute URL
> IIS does not "follow" 302 - IIS is the server - a 302 is sent to a client.
>
> Perhaps if you explained what you were doing, or attempting to do, in more
> complete detail, then we might understand what's going on, and be able to
> provide advice. At the moment, the picture you paint is incomplete, and
> doesn't really make a lot of sense to someone standing on the outside of
> your organisation.
>
> Cheers
> Ken
- Next message: Paul: "Service(Default Web Site)\Current Connections limited to 35?"
- Previous message: Consultant: "Re: Remove FTP Login Prompt"
- In reply to: Ken Schaefer: "Re: Strange test results on IIS6 when 404 set to custom ASP redirect"
- Next in thread: Ken Schaefer: "Re: Strange test results on IIS6 when 404 set to custom ASP redirect"
- Reply: Ken Schaefer: "Re: Strange test results on IIS6 when 404 set to custom ASP redirect"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|