About Me

My photo
Working as Technical Lead in CollabNET software private limited.

Wednesday, 3 June 2009

Apache <IfDefine> Directive

This is used to process some section in httpd.conf based on the system argument.

The directives within an <ifdefine></ifdefine> section are only processed if the "test" variable is true. If "test" variable is false, everything between the start and end markers is ignored.

Example:

httpd -D test -k start

Starting the httpd with system parameter "test" will execute the below section or else it will skip those
<ifdefined>
...
...
</ifdefined>

This will be useful sometime when you try loading modules on specific arguments.

No comments: