Perrin Harkins wrote: > Jonathan Vanasco wrote: > >> $self->{'ApacheRequest'}->status(Apache2::Const::REDIRECT); > > > Don't do that. That's an internal apache code, not an HTTP code. The > HTTP code would be something like Apache2::Const::HTTP_MOVED_TEMPORARILY.
actually, REDIRECT is an alias for HTTP_MOVED_TEMPORARILY. from modperl_constants.c: if (strEQ(name, "REDIRECT")) { return newSViv(HTTP_MOVED_TEMPORARILY); } the thing that usually trips people up is HTTP_OK is 200 but OK is 0, so $r->status(HTTP_OK) is proper but $r->status(OK) makes no sense - as perrin correctly pointed out, $r->status() always needs to be set to an HTTP status code (like 200 or 302) and not an internal apache one (like OK, DECLINED, or DONE). --Geoff