Hi!

Please, help me. How to configure so that if this header X-Requested-With XMLHttpRequest was requested, Nginx will send answer in header Cache-Control "no-cache"?


I know it is wrong, just for exsample.
if ($http_x_requested_with = XMLHttpRequest) {
add_header Cache-Control "no-cache";
}

Best regards,
Rostyslav
Sorry, only registered users may post in this forum.

Click here to login

Online Users

Guests: 291
Record Number of Users: 8 on April 13, 2023
Record Number of Guests: 421 on December 02, 2018
Powered by nginx      Powered by FreeBSD      PHP Powered      Powered by MariaDB      ipv6 ready