Le 22/03/2012 à 22:50, Igor Cicimov a écrit :
"The problem I'm facing here seems to rely in the fact that the
variables I'm trying to use (like "THE_REQUEST", for example) are only
defined within mod_rewrite's scope, and are not available to other
directives like SetenvIf."

And i dont think this is correct i have used SetEnvIf with REQUEST_URI
before.

You're certainly right. REQUEST_URI is a standard variable, which can be used in CGIs and the rest, from what the documentation says.

This makes my problem even stranger...

Following your advice, I checked whether I still had a Location statement somewhere, but no, I had removed after our first exchange, when you showed me that solution wasn't useable.

Then I tried to stick with the SetEnvIf method. Though I don't think statements are case-sensitive, I wrote it exactly that way, but still no luck.

Sounds rather simple:

 Header add X-Debug-Request-URI "%{REQUEST_URI}e"

 SetEnvIf REQUEST_URI "/onlinestore/checkout.*" CheckingOut=1
 Header add X-CheckingOut "checking-out" env=CheckingOut


Behaviour:
1) the X-Debug-Request-URI header is correct in the HTTP response, example:

X-Debug-Request-URI: /cartes-en-ligne/checkout/

2) the X-CheckingOut header, however, is NOT set. :-(

All seems to go as if the REQUEST_URI seen by the SetEnvIf statement had already been modified by the RewriteRules. I haven't found any way to save it in another env. variable (let's say SAVED_REQUEST_URI) before it gets used...

This is driving me crazy. Thanks anyway for all your suggestions.

Best regards,

Bruno

--
- Service Hydrographique et Oceanographique de la Marine  -  DMGS/INF
-  13, rue du Chatellier -  CS 92803  - 29228 Brest Cedex 2, FRANCE
-     Phone: +33 2 98 22 17 49  -  Email: bruno.tregu...@shom.fr

---------------------------------------------------------------------
To unsubscribe, e-mail: users-unsubscr...@httpd.apache.org
For additional commands, e-mail: users-h...@httpd.apache.org

Reply via email to