Detect Apache version in apache config?

后端 未结 5 497
醉酒成梦
醉酒成梦 2020-12-30 00:48

tl;dr: How do I do the following in a .conf or .htaccess file:


  # Do A


  # Do B
&         


        
5条回答
  •  爱一瞬间的悲伤
    2020-12-30 01:08

    You can run different versions of Apache on the same host. Q: What's wrong with separate config files in separate directories? I honestly believe that's probably the cleanest approach...

    Nevertheless, Apache .conf files allow an , which you can specify at runtime with "-D":

    http://httpd.apache.org/docs/2.0/mod/core.html#ifdefine

提交回复
热议问题