3

I'm trying to set up my site to allow CORS for cross domain scripting, however this seems to require mod_header to be enabled in my .htaccess file. I don't have much experience dealing with apache.

I tried to google installing mod_header in apache on mac os but couldn't find any.

I tried this user@mymac:~$ httpd -l and here are the modules currently installed.

  core.c
  prefork.c
  http_core.c
  mod_so.c

Is anyone with knowledge able to tell me how to install mod_header in Mac OS?

Thanks

user2028856
  • 3,063
  • 8
  • 44
  • 71

1 Answers1

9

I believe you're referring mod_headers. Normally it's already installed as shared module in apache.

Try this:

$ httpd -M |grep header

You should see:

Syntax OK
 headers_module (shared)

If not, go to /etc/apache2/httpd.conf, find line below and uncomment it

# LoadModule headers_module libexec/apache2/mod_headers.so
Tony Chen
  • 1,804
  • 12
  • 13