This question already has an answer here:
- Why not use a WAMP stack? 4 answers
Stack trying to migrate a configuration from Linux to Windows Apache 2.2 (via WAMP)
We are trying to set an ENV Apache variable to be used as DocumentRoot and rest of directives thereafter so we can use the same set of confs on server and local working copies of developers.
In Debian Linux Apache we have an envvars file that is loaded with "EXPORT" directives. This does not work on Windows but
Setenv ROOT_TO_FILES "C:/wamp/www/test"
Seems to work as displayed by a phpinfo()
But when we use it inside a DocumentRoot directive of an vhost:
Apache looks for that literal text under its own root.
This is the way we use it in Linux but we've also tried the syntax of env=ROOT_TO_FILES
The apache doc seems clear about how to "define" but not how to use. Also I see Apache 2.4 includes a new "Define" directive that seems to do exactly this which makes me think that it might not possible in previous versions.
Any samples of use under Windows Apache would be appreciated.