admin管理员组

文章数量:1406060

I have a primary domain at www.example. We installed Wordpress at www.example/wp.

When we set up the redirect from www.example to www.example/wp, it works, but we would like to hide the /wp from the URL.

I have tried to edit the .htaccess and remove the original redirect as recommended by Wordpress, but that resulted in a 403 error.

<IfModule mod_rewrite.c>
RewriteEngine on
RewriteCond %{HTTP_HOST} ^(www.)?example$
RewriteCond %{REQUEST_URI} !^/wp/
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ /wp/$1
RewriteCond %{HTTP_HOST} ^(www.)?example$
RewriteRule ^(/)?$ wp/index.php [L] 
</IfModule>

Any help would be much appreciated.

Thanks!

本文标签: Redirecting Primary domain to a Wordpress Installation in the Subdirectory without changing URL