0

I want to access an environment variable inside the rewrite rules which is previously set using SetEnv e.g., SetEnv intl UK

How do I access this "intl" inside the rules later (not in PHP or any other script)?

Roy
  • 575
  • 2
  • 8
  • 17

1 Answers1

0

Sorry, you can't.

The SetEnv directive runs late during request processing meaning that directives such as SetEnvIf and RewriteCond will not see the variables set with it.

Please refer to this previous question. RewriteCond with SetEnv

Community
  • 1
  • 1
unione
  • 371
  • 2
  • 6