ฉันใช้ proxy_hide_header X-Powered-By คำสั่ง แต่มันใช้งานไม่ได้ ฉันต้องใช้ expose_php ตัวเลือกใน php.ini.
มีอะไรที่แตกต่างกันระหว่าง proxy_hide_header และ expose_php ตัวเลือก?
นี่คือการกำหนดค่า
server {
listen 80;
server_name .ailms.me;
root /data/blog/ailms.me/;
index index.php index.html index.htm;
error_page 500 502 503 504 /50x.html;
proxy_hide_header X-Powered-By; # i put it here, not working
location ~ ^/.+\.php(\/.*)?$ {
proxy_hide_header X-Powered-By ; # still not working
ths! คุณพูดถูก ฉันใช้ผิดทิศทาง ฉันควรใช้ fastcgi_hide_header แทน :)
—
ailms
proxy_hide_headerไม่ควรทำงาน อาจมีปัญหากับการกำหนดค่าของคุณ?