-
Notifications
You must be signed in to change notification settings - Fork 219
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add HTTP Headers for cached pages with PHP #801
Comments
Hi @ambrosso , did you have success in adding custom http headers to the cache? I would like to add specific Content Security Policys on specific pages and searching a way to do that. Thank & Best Regards! |
@GeekPress @Tabrisrp This seems very specific and wouldn't apply to the bulk of our customers. Shall we close this? If someone wants to do this:
|
@arunbasillal You're right, let's closing this issue. |
Maybe this should be revisited in some form. Custom headers are needed to integrate with Cloudflare APO and likely similar offerings from other services in the future. #3180 Would also be nice to be able to add push headers for example for a logo to improve FCP. WP Rocket should also have the option to send a push header for its own concatenated/minified CSS and JS. |
WP Rocket user can not use 103 early hints in Cloud Flare. It is not so cool. |
How to add custom HTTP Headers for cached pages with PHP hook?
When server is not Apache, and thereis no access to NGINX server configuration.
For not cached pages HTTP Headers can be added with PHP in Plugin/functions.php/MU Plugin, but not for cached pages.
For all site, including cached pages, they can be added in wp-config.php file.
Is it possible to add HTTP Headers with some function or hook to WP Rocket plugin?
And how to add custom HTML content only to cached pages?
The text was updated successfully, but these errors were encountered: