Re: How to set environment variable from RewriteMap? (was Re: mod_rewrite E flag does not set env. variable)

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Mon, 2008-03-10 at 14:01 +0100, Krist van Besien wrote:
> On Mon, Mar 10, 2008 at 1:44 PM, Thorsten Scherler
> <thorsten.scherler.ext@xxxxxxxxxxxxxxxxxxx> wrote:
> 
> >  RewriteMap portadaboja txt:/opt/datos/httpd/redirect.txt
> >  SetEnv FOCUS ${portadaboja:boletin}
> >
> >  but the variable will the return the literal context. Meaning
> >  ${portadaboja:boletin} and not the result of this expression.
> 
> That expression will only be evaluated in the context of a RewriteRule
> or a RewriteCond

I thought so, thanks for clarification.

> >  Does somebody has an idea how I can save either whether a rewrite had
> >  happened or the result of the rewriteMap expression.
> 
> If you want to save that information during request processing you can
> use an environment variable, just like you did. If you want to save
> information from one request to another you need another mechanism.

Which mechanism would you suggest?

> However, you are doing the following:
> 
> RewriteRule "^/BOJA$"
> "http://%{HTTP_HOST}/boja/${portadaboja:boletin}"; [E=FOCUS:true,L]
> 
> (now with L as you mentioned, however that makes the
> http://%{HTTP_HOST} completely superfluous)
> 
> That means that your SSI processing will happen inside a file whose
> name is the result of the rewrite map. So you know what the result is,
> don't you? You're getting it as part of the URL...

Well, like I said the other mail: "L flag, that is working just fine
however that is not solving my problem, since I depending on a rewrite
of the url."

Thanks very much for explaining.

salu2
-- 
Thorsten Scherler                                 thorsten.at.apache.org
Open Source Java                      consulting, training and solutions


---------------------------------------------------------------------
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@xxxxxxxxxxxxxxxx
   "   from the digest: users-digest-unsubscribe@xxxxxxxxxxxxxxxx
For additional commands, e-mail: users-help@xxxxxxxxxxxxxxxx


[Index of Archives]     [Open SSH Users]     [Linux ACPI]     [Linux Kernel]     [Linux Laptop]     [Kernel Newbies]     [Security]     [Netfilter]     [Bugtraq]     [Squid]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]

  Powered by Linux