You are viewing a plain text version of this content. The canonical link for it is here.
Posted to users@httpd.apache.org by aparna aryan <ap...@gmail.com> on 2011/01/07 13:24:59 UTC

[users@httpd] Regarding the redirect rules

Hello,

Can any one please explain the meaning of this rule?

RewriteEngine On
RewriteCond %{HTTP:FRONTEND-HTTPS} !on
RewriteRule ^/(wps/myportal/protected/.*) https://internal.ericsson.com/$1[R,L]

RE: [users@httpd] Regarding the redirect rules

Posted by "motty.cruz" <mo...@gmail.com>.
http://borkweb.com/story/apache-rewrite-cheatsheet

 


L

Last  Rule

Stop the rewriting process here and don't apply any more rewriting rules.
This corresponds to the Perl last command or the break command from the C
language. Use this flag to prevent the currently rewritten URL from being
rewritten further by following rules. For example, use it to rewrite the
root-path URL ('/') to a real one, e.g., '/e/www/'.

 


R[=code]

Redirect to new URL, with optional code (see below).

Prefix Substitution with http://thishost[:thisport]/ (which makes the new
URL a URI) to force a external redirection. If no code is given a HTTP
response of 302 (MOVED TEMPORARILY) is used. If you want to use other
response codes in the range 300-400 just specify them as a number or use one
of the following symbolic names: temp (default), permanent, seeother. Use it
for rules which should canonicalize the URL and give it back to the client,
e.g., translate ``/~'' into ``/u/'' or always append a slash to /u/user,
etc.

 

 

From: aparna aryan [mailto:aparnapuram@gmail.com] 
Sent: Friday, January 07, 2011 4:43 AM
To: users@httpd.apache.org; joost@sanguis.xs4all.nl
Subject: Re: [users@httpd] Regarding the redirect rules

 

Thanks a lot Joost, Can u please explain what does "[R,L]" mean too?

On Fri, Jan 7, 2011 at 6:11 PM, Joost de Heer <jo...@sanguis.xs4all.nl>
wrote:

On Fri, January 7, 2011 13:24, aparna aryan wrote:
> Hello,
>
> Can any one please explain the meaning of this rule?
>
> RewriteEngine On
> RewriteCond %{HTTP:FRONTEND-HTTPS} !on
> RewriteRule ^/(wps/myportal/protected/.*)
> https://internal.ericsson.com/$1[R,L]
<https://internal.ericsson.com/$1%5bR,L%5d> 
>

If the HTTP-header 'FRONTEND-HTTPS' isn't set to 'on', then redirect
/wps/myportal/protected/[suburl] to
https://internal.ericsson.com/[suburl]
<https://internal.ericsson.com/%5bsuburl%5d> .

Joost

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

 


Re: [users@httpd] Regarding the redirect rules

Posted by aparna aryan <ap...@gmail.com>.
Thanks a lot Joost, Can u please explain what does "[R,L]" mean too?

On Fri, Jan 7, 2011 at 6:11 PM, Joost de Heer <jo...@sanguis.xs4all.nl>wrote:

> On Fri, January 7, 2011 13:24, aparna aryan wrote:
> > Hello,
> >
> > Can any one please explain the meaning of this rule?
> >
> > RewriteEngine On
> > RewriteCond %{HTTP:FRONTEND-HTTPS} !on
> > RewriteRule ^/(wps/myportal/protected/.*)
> > https://internal.ericsson.com/$1[R,L]
> >
>
> If the HTTP-header 'FRONTEND-HTTPS' isn't set to 'on', then redirect
> /wps/myportal/protected/[suburl] to
> https://internal.ericsson.com/[suburl].
>
> Joost
>
> ---------------------------------------------------------------------
> 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
>
>

Re: [users@httpd] Regarding the redirect rules

Posted by Joost de Heer <jo...@sanguis.xs4all.nl>.
On Fri, January 7, 2011 13:24, aparna aryan wrote:
> Hello,
>
> Can any one please explain the meaning of this rule?
>
> RewriteEngine On
> RewriteCond %{HTTP:FRONTEND-HTTPS} !on
> RewriteRule ^/(wps/myportal/protected/.*)
> https://internal.ericsson.com/$1[R,L]
>

If the HTTP-header 'FRONTEND-HTTPS' isn't set to 'on', then redirect
/wps/myportal/protected/[suburl] to
https://internal.ericsson.com/[suburl].

Joost

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