Mod_headers is simply not working

apache-2.2

I have enabled mod_headers in my apache (2.2 on windows server 2008) config but it is not doing anything.

I have moved the headers directive to all parts of the config and even to a .htaccess file in the root and still it does nothing.

<VirtualHost *:80>

    ServerName [dedacted]
    ServerAdmin [dedacted]
    DocumentRoot "C:\data"

    Header always append Access-Control-Allow-Origin "*"

    ErrorLog "logs/data.log"
    CustomLog "logs/data.log" common

    <Directory C:\data>
        Options FollowSymLinks All
        AllowOverride All
        Order deny,allow
        Allow from all
    </Directory>

</VirtualHost>

I have checked the module is loaded via the command line and phpinfo(), see below:

Loaded Modules core mod_win32 mpm_winnt http_core mod_so mod_actions mod_alias mod_asis mod_auth_basic mod_authn_default mod_authn_file mod_authz_default mod_authz_groupfile mod_authz_host mod_authz_user mod_autoindex mod_cgi mod_dir mod_env **mod_headers** mod_include mod_isapi mod_log_config mod_mime mod_negotiation mod_rewrite mod_setenvif mod_php5 

Im going out of my mind, and even getting to the point where im considering reinstalling apache.

Can anyone help!

Best Answer

Any chance you're doing this for the same reason the rest of us are doing this now, custom font files? If so, here's what I wound up doing, might help:

<FilesMatch "\.(ttf|otf|eot)$">
  <IfModule mod_headers.c>
    Header set Access-Control-Allow-Origin "*"
  </IfModule>
</FilesMatch>