多站点安装上的非WordPress子域 时间:2018-10-01 作者:Danielh 我有Wordpress multisite,我想从multisite中排除一个子域。我有点困惑。Wordpress多站点目录:/var/www/XYZ(domain example.com,subdomain:1subdomain.example.com)我要排除目录的网站:/var/www/ABC(subdomain:2subdomain.example.com如何排除2子域。实例来自多站点的com?仍有重定向。。谢谢你的帮助! 1 个回复 SO网友:Greg Much 在里面htaccess您必须访问(确保将目录设置正确)!^//ABC//em>)RewriteEngine on RewriteCond %{HTTP_HOST} ^(www.)?2subdomain.example.com$ RewriteCond %{REQUEST_URI} !^/../ABC/ RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule ^(.*)$ /ABC/$1 RewriteCond %{HTTP_HOST} ^(www.)?2subdomain.example.com$ RewriteRule ^(/)?$ ABC/index.php [L] https://codex.wordpress.org/Giving_WordPress_Its_Own_Directory 结束 文章导航