server
{
listen ;
server_name local.*****.com;
index index.html index.htm index.php;
root /home/wwwroot/******/public; #error_page /.html;
include enable-php-pathinfo.conf; location /nginx_status
{
stub_status on;
access_log off;
} location ~ .*\.(gif|jpg|jpeg|png|bmp|swf)$
{
expires 30d;
} location ~ .*\.(js|css)?$
{
expires 12h;
} location ~ /\.
{
deny all;
} location / {
if (!-e $request_filename) { //~~~~访问可以不加index.php
rewrite ^(.*)$ /index.php?s=/$ last;
}
} access_log /home/wwwlogs/access_dexin.log;
}