Setting a Varing Directory Structure for Static Utility Files

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • hsheboul
    New Member
    • May 2009
    • 14

    Setting a Varing Directory Structure for Static Utility Files

    Thanks to Markus for pointing me to all the Apache stuff


    My Web site is hosted on a shared Linux hosting, that runs the Apache 2.2

    I got multiple static "utility" files: CSS, JavaScripts, Impages, etc. In order to maintain a coherent and consistent structure, I put all these kind of utility files in one directory hierarchy. However, this directory structure might change in the future.

    What I want is to put this directory location, perhaps as an absolute path, starting from the root, in an (environment) "variable", for instance, UTILITYD. If this directory ever changed, then UTILITYD changes accordingly,
    Code:
    export UTILITYD=$HOME/utility
    Another choice might be to set UTILITYD to the actual HTTP URL, e.g.
    Code:
    export UTILITYD=http://www.example.com/utility
    I'm not even sure if this can be done using SSI
    Code:
    <!--#set var="utility" value="some_form_of_the_directory" -->
    Since this would end up again into changing each HTML page into the new directory path that holds the utility files.

    Issues: UTILITYD should be accessed via the Apache environment; this can be achieved via the Apache SetEnv or PassEnv directives. But this requires two things, according to the Apache docs
    1. access to the Apache configuration file
    2. restarting the Apache server.


    My host doesn't allow the former, how about the latter. Even I'm not quit sure if any host allows restarting its own Apache.

    Is there any suggestions of how this can be resolved or even using any of the SSI techniques or what else?
Working...