• If you are still using CentOS 7.9, it's time to convert to Alma 8 with the free centos2alma tool by Plesk or Plesk Migrator. Please let us know your experiences or concerns in this thread:
    CentOS2Alma discussion

Issue "Header set" in .htaccess not working with "Smart static files processing" enabled

JoeShmoe

New Pleskian
I want to add a HTTP header to images in a certain directory.
However when adding
Code:
Header set test 1
to .htaccess in the directory, the the header isn't added to the files.

Only after disabling "Smart static files processing" the header shows up.

I could just leave it disabled, but Plesk suggests disabling is "only for troubleshooting".
Tested on two servers (centos and ubuntu) with the latest Plesk.
 
  1. "Smart static files processing" means nginx processes the requests without passing it along to apache, serving the files itself directly.
  2. nginx does not use .htaccess. Only Apache does.
  3. So for this to work, you'll need further nginx directives, not .htaccess.
 
Back
Top