YY-LIN 发表于 2018-11-12 08:02:55

discuz的nginx配置

server {  
    listen       80;
  
    server_name www.ccvita.com ccvita.com;
  

  
    location /{
  
         index         index.html index.htm index.php;
  
         root            /www/www.ccvita.com;
  
         rewrite ^(.*)/archiver/((fid|tid)-[\w\-]+\.html)$ $1/archiver/index.php?$2 last;
  
         rewrite ^(.*)/forum-(+)-(+)\.html$ $1/forumdisplay.php?fid=$2&page=$3 last;
  
         rewrite ^(.*)/thread-(+)-(+)-(+)\.html$ $1/viewthread.php?tid=$2&extra=page%3D$4&page=$3 last;
  
         rewrite ^(.*)/profile-(username|uid)-(.+)\.html$ $1/viewpro.php?$2=$3 last;
  
         rewrite ^(.*)/space-(username|uid)-(.+)\.html$ $1/space.php?$2=$3 last;
  
         rewrite ^(.*)/tag-(.+)\.html$ $1/tag.php?name=$2 last;
  

  
    }
  

  
      location ~\.php$ {
  
                include fastcgi_params;
  
                fastcgi_index index.php;
  
                fastcgi_pass127.0.0.1:8694;
  
                fastcgi_param SCRIPT_FILENAME /www/www.ccvita.com$fastcgi_script_name;
  
      }
  

  
    location /www.ccvita.com-status {
  
         stub_status on;
  
         access_logoff;
  
    }
  
}


页: [1]
查看完整版本: discuz的nginx配置