I have a problem, the following is the server block. all rewrites work well except for the last location block. when the link is accessed. it gives a 404 error. cant seem to find a solution.
server
{
listen 80;
server_name fontistic.com;
location / {
root /var/www/fontistic.com/;
index index.html index.htm index.php;
}
location ~ \.html$ {
rewrite ^/(.*).html /$1.php last;
}
location /top_rated {
rewrite ^/top_rated/(.*)/$ /top_fonts.php?page=$1;
rewrite ^(.*)$ /top_fonts.php;
}
location /fonts {
rewrite ^/fonts/(.*)/(.*)$ /font_details.php?f=$1;
}
}
the link being accessed is http://fontistic.com/fonts/1416/berthside.html