子域index.php文件与主域冲突

时间:2016-12-01 11:14:01

标签: php wordpress .htaccess codeigniter subdomain

我的子域名http://web.example.com/和主域http://example.com/ 我的网站托管在gandi.net服务器上,当我创建子域名时,它会自动创建子域名文件夹web.example.com

文件夹结构是:

主域名:/lamp0/web/vhosts/example.com/htdocs/和源代码wp

子域:/lamp0/web/vhosts/web.example.com/htdocs/和源代码ci

WordPress中的主域名网站和codeigniter框架中的子域名网站。 当我运行子域时,它调用WordPress index.php文件

Wordpress .htaccess是:

# BEGIN WordPress
<IfModule mod_rewrite.c>

RewriteEngine on

RewriteBase /
RewriteRule ^index\.php$ - [L]
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /index.php [L]
</IfModule>

# END WordPress

并且codeigniter .htaccess是:

<IfModule mod_rewrite.c>
RewriteEngine On
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule ^(.*)$ index.php/$1 [L] 
</IfModule>

任何人都可以建议我问题在哪里?为什么在我尝试子域名时调用主域文件。

0 个答案:

没有答案
相关问题