httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Igor Galić <i.ga...@brainsware.org>
Subject Re: [users@httpd] A rewrite rule
Date Sat, 26 Nov 2011 18:13:53 GMT


----- Original Message -----
> Thanks, Igor,

There's two Igors on this List
I am not a beautiful unique snowflake :-/

> I want the url in user's browser looks like "tc.example.com/what", so
> a 302 redirect is not ok.
> 
> 
> Any other way to do this?
> Dennis

A I already wrote:

  Essentially you want to do reverse proxying.

  http://www.apachetutor.org/admin/reverseproxies




> --- On Fri, 11/25/11, Igor Cicimov <icicimov@gmail.com> wrote:
> 
> 
> 
> From: Igor Cicimov <icicimov@gmail.com>
> Subject: Re: [users@httpd] A rewrite rule
> To: users@httpd.apache.org
> Date: Friday, November 25, 2011, 8:06 PM
> 
> 
> Is this working?
> 
> 
> 
> RewriteCond %{HTTP_HOST} \.tc\.example\.com$
> RewriteRule ^/(.*)$ http://example.com/good/tc/$1 [R,L]
> 
> or you just want anything to go to /good/tc ?
> 
> 
> 
> RewriteCond %{HTTP_HOST} \.tc\.example\.com$
> RewriteRule ^/.* http://example.com/good/tc [R,L]
> 
> 
> 
> On Fri, Nov 25, 2011 at 10:46 PM, Dennis < arsenepark@yahoo.com.cn >
> wrote:
> 
> 
> 
> Hi, guys,
> 
> 
> I want to rewrite from " tc.example.com/xyz " to "
> example.com/good/tc "
> 
> 
> I tried the following rewrite rule, but it doesnot work.
> 
> 
> RewriteCond %{HTTP_HOST} \.tc\.example\.com$
> RewriteRule ^/(.*) /good/$1 [NC,P,L]
> 
> 
> Any idea how to do it?
> 
> 
> Thanks.
> Dennis
> 

-- 
Igor Galić

Tel: +43 (0) 664 886 22 883
Mail: i.galic@brainsware.org
URL: http://brainsware.org/
GPG: 6880 4155 74BD FD7C B515  2EA5 4B1D 9E08 A097 C9AE

---------------------------------------------------------------------
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