in reply to Re^2: Redirect problem
in thread Redirect problem

AFAIK, the Location header must contain an absolute URL, not a relative.

Use Firebug or Wireshark to find out what is sent to the browser. I guess Apache enforces status 404, so you won't get the 30x redirection that you expect. Perhaps you need to add a Status header.

Alexander

--
Today I will gladly share my knowledge and experience, for there are no sweeter words than "I told you so". ;-)

Replies are listed 'Best First'.
Re^4: Redirect problem
by DreamT (Pilgrim) on Feb 01, 2012 at 09:29 UTC
    It actually works when calling /cgi-bin/errorpage.pl directly, so I guess that the Location isn't the problem, this is probably related more to the Apache handling?

      So use Firebug, Wireshark, or if you have no better idea, use

      lwp-request -m GET -e -s -S http://your.server/some/page/that/does/not/exist

      and look at the HTTP headers returned.

      Alexander

      --
      Today I will gladly share my knowledge and experience, for there are no sweeter words than "I told you so". ;-)
Re^4: Redirect problem
by Anonymous Monk on Feb 01, 2012 at 10:35 UTC

    AFAIK, the Location header must contain an absolute URL, not a relative.

    HTTP location says different

      Actually, the linked page says about relative redirects:

      This example, while incorrect based on the internet standard, will often work in popular browsers.

      Which makes the sentence "The Location header must contain an absolute URL, not a relative." correct as in accordance with the standard.

        Maybe as it applies to HTTP, but AFAIK, under CGI, appache will make it absolute