Skip to content

Commit c395c01

Browse files
author
Arturo Blanco
authored
Update prestashop.tpl
1 parent 6332de0 commit c395c01

File tree

1 file changed

+3
-7
lines changed

1 file changed

+3
-7
lines changed

install/deb/templates/web/nginx/php-fpm/prestashop.tpl

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -100,22 +100,18 @@ server {
100100
}
101101

102102
location / {
103-
if (!-e $request_filename)
104-
{
105-
rewrite ^(.+)$ /index.php?q=$1 last;
106-
}
103+
try_files $uri $uri/ /index.php?$args;
107104
108105
location ~* ^.+\.(ogg|ogv|svg|svgz|swf|eot|otf|woff|woff2|mov|mp3|mp4|webm|flv|ttf|rss|atom|jpg|jpeg|gif|png|ico|bmp|mid|midi|wav|rtf|css|js|jar)$ {
109106
expires 30d;
110107
fastcgi_hide_header "Set-Cookie";
111108
}
112109

113110
location ~ [^/]\.php(/|$) {
111+
try_files $fastcgi_script_name /index.php$uri&$args =404;
114112
fastcgi_split_path_info ^(.+\.php)(/.+)$;
115113
fastcgi_param SCRIPT_FILENAME $document_root$fastcgi_script_name;
116-
if (!-f $document_root$fastcgi_script_name) {
117-
return 404;
118-
}
114+
119115
fastcgi_pass %backend_lsnr%;
120116
fastcgi_index index.php;
121117
include /etc/nginx/fastcgi_params;

0 commit comments

Comments
 (0)