Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 0 additions & 5 deletions nginx.conf
Original file line number Diff line number Diff line change
Expand Up @@ -26,11 +26,6 @@ server {
deny all;
}

location ~* \.(css|js|gif|ico|jpeg|jpg|png|svg|woff|woff2|ttf|eot)$ {
expires 1y;
add_header Cache-Control "public, immutable";
}

add_header X-Frame-Options "SAMEORIGIN" always;

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

While removing the extension block solves the routing issue, you've lost the browser caching headers (Expires, Cache-Control) for your actual static assets. Consider moving these headers into a general location block or adding them to your main location / if you want to maintain performance for real static files.

Suggested change
add_header X-Frame-Options "SAMEORIGIN" always;
location / {
try_files $uri $uri/ /index.php?$query_string;
# Re-add caching for static assets here or in a more specific way that doesn't intercept PHP
}
add_header X-Frame-Options "SAMEORIGIN" always;
add_header X-Content-Type-Options "nosniff" always;
add_header X-XSS-Protection "1; mode=block" always;

add_header X-Content-Type-Options "nosniff" always;
add_header X-XSS-Protection "1; mode=block" always;
Expand Down
Loading