如果是ngnix中

使用以下规则

location / {
    if (!-e $request_filename) {
            rewrite  ^(.*)$ /index.php?s=/$1  last;
            break;
    }
}

 

如果是apache中

修改.htaccess

<IfModule mod_rewrite.c>
Options +FollowSymlinks
RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-d
RewriteCond %{REQUEST_FILENAME} !-f
RewriteRule ^(.*)$ index.php?s=$1 [QSA,PT,L]
</IfModule>

 

相关文章:

  • 2021-10-23
  • 2021-10-30
  • 2022-12-23
  • 2022-01-06
  • 2021-08-13
  • 2022-12-23
  • 2022-02-25
  • 2022-01-21
猜你喜欢
  • 2021-11-25
  • 2021-12-08
  • 2022-12-23
  • 2021-12-16
  • 2022-12-23
  • 2022-12-23
  • 2021-12-01
相关资源
相似解决方案