httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Joshua Slive" <jos...@slive.ca>
Subject Re: [users@httpd] Help!! mod_rewrite location header cant get correct syntax
Date Tue, 24 Jul 2007 01:59:20 GMT
On 7/23/07, Eric Covener <covener@gmail.com> wrote:
> On 7/23/07, Jeff Murch <jmurch@cox.net> wrote:
> > I need to rewrite a location header as follows but I can't seem to get the
> > syntax correct:
> >
> > RewriteRule ^Location: http://server1.domain.com  Location:
> > server2.domain.com [R,L]
>
> Something like this?
>
> RewriteCond %{HTTP:Location} ^http://server1\.domain\.com(.*)
> RewriteRule .* http://server2.domain.com%1 [R,L]

Location is usually a response header, and therefore can't be
rewritten like that. (That notation is for request headers.)

mod_rewrite is probably not the tool for this at all. Why exactly do
you need to rewrite the Location header and in what circumstance?

Joshua.

---------------------------------------------------------------------
The official User-To-User support forum of the Apache HTTP Server Project.
See <URL:http://httpd.apache.org/userslist.html> for more info.
To unsubscribe, e-mail: users-unsubscribe@httpd.apache.org
   "   from the digest: users-digest-unsubscribe@httpd.apache.org
For additional commands, e-mail: users-help@httpd.apache.org


Mime
View raw message