第一步:修改.htaccess檔案如下
<IfModule mod_rewrite.c> Options +FollowSymlinks -Multiviews RewriteEngine On RewriteCond %{REQUEST_FILENAME} !-d RewriteCond %{REQUEST_FILENAME} !-f RewriteRule ^(.*)$ index.php?/$1 [QSA,PT,L] </IfModule>
第二步:修改nginx.conf 的 location / { } 部分
我修改的是對應站點的nginx組態檔

if (!-e $request_filename){ rewrite ^/(.*)$ /index.php?s=/$1 last; }
轉載請註明出處,本文鏈接:https://www.uj5u.com/houduan/5962.html
標籤:PHP
下一篇:tp5模板顯示時間格式
