【发布时间】:2016-09-17 16:57:15
【问题描述】:
我已将 WordPress 移至名为 /site 的子文件夹中,但 URL 现在显示为 http://www.example.com/site。我希望它在没有 /site/ 子目录的情况下显示。
这是我当前的.htaccess 代码
RewriteEngine On
RewriteBase /site/
RewriteRule ^index\.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /site/index.php [L]
如何从可见 URL 中删除物理子目录?
【问题讨论】:
标签: php wordpress .htaccess url-rewriting