• The Horde webmail has been deprecated. Its complete removal is scheduled for April 2025. For details and recommended actions, see the Feature and Deprecation Plan.
  • We’re working on enhancing the Monitoring feature in Plesk, and we could really use your expertise! If you’re open to sharing your experiences with server and website monitoring or providing feedback, we’d love to have a one-hour online meeting with you.

Resolved How to remove Cache-Control Use .htaccess?

v123shine

New Pleskian
Hi,

How to remove must-revalidate and max-age=0 from Cache-Control header using .htaccess?

And How to remove X-Powered-By PHP/5.6.24 using .htaccess?
I try using this code: Header unset X-Powered-By but still not work.

Can someone help me, please! Thanks

Note:
- I'm using Plesk 12.0.18
- PHP run as FastCGI
- Web Server Setting, using Smart static files processing with Serve static files directly by nginx.
 
Last edited:
Hi v123shine,

pls. be informed, that
How to remove must-revalidate and max-age=0 from Cache-Control header using .htaccess?
conflicts with the fact
- Web Server Setting, using Smart static files processing with Serve static files directly by nginx.
NGINX can't read ".htaccess" - files... you have to use "additional directives", when you use nginx.

Before giving additional suggestions to this question, can you pls. explain, why you would like to remove cache-control?


And How to remove X-Powered-By PHP/5.6.24 using .htaccess?
I try using this code: Header unset X-Powered-By but still not work.
To remove this information, consider to modify:

Code:
...
expose_php = off
...

at your depending PHP.ini - file(s).

Hint:
You could find it usefull, to use "sed", after you located your depending PHP.ini - file(s):

Examples:
Code:
find / -type f -name "*.ini" -exec grep -i -H "expose_php ="  {} \;
Code:
sed -i -e 's/expose_php = on/expose_php = off/' /etc/php/php.ini
 
Back
Top