Setting P3P headers in Apache causes Internal Server Error

4.1k views Asked by At

I wanted to set the P3P Headers by adding them to .htaccess using the following:

<IfModule mod_headers.c>
Header set P3P "CP="ALL DSP COR CUR ADM TAI OUR IND COM NAV INT""
</IfModule>

However, this causes an Internal Server Error. The only related entry in the server log I can find is .htaccess : Header has too many arguments

As far as I can tell, mod_headers.c loaded.

Any idea on how to fix this? Thanks!

1

There are 1 answers

0
William Troup On BEST ANSWER

This line:

Header set P3P "CP="ALL DSP COR CUR ADM TAI OUR IND COM NAV INT""

Should be written as:

Header set P3P "CP=\"ALL DSP COR CUR ADM TAI OUR IND COM NAV INT\""