Добрый день.
htaccess:
AddDefaultCharset UTF-8
RewriteEngine on
RewriteRule ^show/([0-9]+)/? index.php?module=show&id=$1 [L]]
Преобразую в nginx:
server {
server_name example.com;
root /home/www/example.com;
index index.php index.html index.htm;
location /show {
rewrite ^/show/([0-9]+)/? "/index.php?m=show&id=$1" last;
}
location ~ \.php$ {
fastcgi_split_path_info ^(.+\.php)(/.+)$;
fastcgi_pass unix:/var/run/php5-fpm.sock;
fastcgi_index index.php;
include fastcgi_params;
}
}
Однако при переходе по ссылке
example.com/show/1 браузер выкачивает php файл.
При этом по ссылке
example.com/show/1/ нормально работает, т.е. слеш в конце все решает.
php-frm