This is a discussion on beginner's question: variable definition in apache config files? within the Apache Web Server forums, part of the Web Server and Related Forums category; is it possible to define a variable in an apache config file? that is, I would like to write myapp = /...
|
|||||||
| FAQ | Members List | Calendar | Search | Today's Posts | Mark Forums Read |
|
|||
|
is it possible to define a variable in an apache config file? that
is, I would like to write myapp = /home/httpd/server/html/applicationrootdir and then say <Directory ${myapp}/subdir> various </Directory> ....and many other ones like it. I have searched for a while, but not stumbled upon this functionality. This would make it a lot easier for me to move trees to different servers and/or locations. Even finding out that this is not possible would be useful. help appreciated. /iaw |
|
|||
|
On 2004-09-26, ivo welch <ivo.welch@anderson.ucla.edu> wrote:
> is it possible to define a variable in an apache config file? AFAIK No. Unless you hack the code of Apache that read the file. But what's the advantage in doing so? > This would make it a lot easier for me to move trees to different > servers and/or locations. Then use a pre-processor to parse *your* 'config' file and produce an ad-hoc configuration file. Sed is the first thing that pop in my mind that could do it. Davide -- Virus error: A virus has been activated in a DOS session. The virus, however, requires Windows. All tasks will automatically be closed and the virus will be activated again. |
| Thread Tools | |
| Display Modes | |
|
|