httpd-users mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Tushar Chavan <tushar.cha...@hotmail.com>
Subject RE: [users@httpd] RewriteRule : How to retain Apache Host in the url
Date Wed, 03 Nov 2010 08:51:54 GMT

Thanks a ton Igor.  P flag worked..
 


Date: Tue, 2 Nov 2010 18:07:26 +1100
From: icicimov@gmail.com
To: users@httpd.apache.org
Subject: Re: [users@httpd] RewriteRule : How to retain Apache Host in the url

Have you tried using the P flag in the RewriteRule?

Cheers,
Igor



On Tue, Nov 2, 2010 at 4:26 PM, Tushar Chavan <tushar.chavan@hotmail.com> wrote:


Hi Eric,
 
We have set SERVER_NAME & HTTP_HOST env. variables but still it is not working.
 
Let me explain our scenario.
 
https://srmdevarp01.domain/irj  ( this url will give us the portal page )
 
On the the portal page there is href  ( href="https://srmdevarp01.domain/sap(bD1lbiZjPTAxNiZkPW1pbg==)/bc/bsp/sap/z_ros_self_reg1/main.htm"
) for self registration.
 
Now when anyone will click on the href they will be redirected to the srmsbx host by rewrite
rule ( RewriteRule  ^/(sap\(.*)         http://srmsbx.domain:8000/$1  )
 
i.e whoever clicks on the self registration button on the portal page , will be re-directed
to http://srmsbx.domain:8000/sap(bD1lbiZjPTAxNiZkPW1pbg==)/bc/bsp/sap/z_ros_self_reg1/main.htm.
 
Now here we want to retain apache host name i.e srmdevarp01 just like we do with   ProxyPreserveHost.
 
Please let me know if there is way to do it.
 
Best Regards,
Tushar

 
> Date: Mon, 1 Nov 2010 08:06:39 -0400
> From: covener@gmail.com
> To: users@httpd.apache.org
> Subject: Re: [users@httpd] RewriteRule : How to retain Apache Host in the url
> 
> On Mon, Nov 1, 2010 at 3:54 AM, Tushar Chavan <tushar.chavan@hotmail.com> wrote:
> > Hi Experts,
> >
> > We have definded rewrite rule as below
> > RewriteEngine on
> > RewriteRule ^/(sap\(.*)         http://srmhost.kjo.com.sa:8000/$1
> > So now whenever url
> > https://apache_host.domain/sap(bD1lbiZjPTAxNiZkPW1pbg==)/bc/bsp/sap/z_ros_self_reg1/main.htm
> > is called, it
> > will re-direct to
> > http://srmhost.kjo.com.sa:8000/sap(bD1lbiZjPTAxNiZkPW1pbg==)/bc/bsp/sap/z_ros_self_reg1/main.htm
> > which is ok.
> 
> %{SERVER_NAME} or %{HTTP_HOST}
> >
> > But can we retain apache_host name in the url so that srmhost is not visible
> > to the outer world.
> >
> > Best Regards,
> > Tushar.
> >
> 
> 
> 
> -- 
> Eric Covener
> covener@gmail.com
> 
> ---------------------------------------------------------------------
> 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