myladeybugg
myladeybugg

Reputation: 329

Wordpress Homepage Gets Redirected to Other CMS Home Page

I have installed WP multisite in my root directory. I also currently have a site running in this directory using Invision Power's IP Content, but renamed the index.php file to accommodate wordpress. I am running IP Board in /forum.

I have created a wordpress page (domain.tld/sample-page/), but when navigating to it, its unable to find it (landing page is not WP, but IP Content with "we could not find the page you were looking for). It looks like my site is looking at the IP Content database before WP so it is unable to find the page/directory in its own database because /sample-page/ does not exist in it, only in the WP database.

When I go to domain.com/index.php (which should bring up my WP blog) I get redirected to my home IP Content page at www.domain.com.

How can I have it look at the WP database for things like this?

My .htaccess file:

# Loads home.php first (ip.content). Wordpress is index.php

DirectoryIndex home.php index.php index.html maintenance.html

<IfModule mod_rewrite.c>
Options -MultiViews
RewriteEngine On
RewriteBase /
RewriteCond %{REQUEST_FILENAME} !.*\.(jpeg|jpg|gif|png|ico)$
RewriteCond %{REQUEST_FILENAME} !-f
RewriteCond %{REQUEST_FILENAME} !-d
RewriteRule . /home.php [L]
</IfModule>


# 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>

# Multisite

RewriteEngine On
RewriteBase /
RewriteRule ^index\.php$ - [L]

# add a trailing slash to /wp-admin
RewriteRule ^([_0-9a-zA-Z-]+/)?wp-admin$ $1wp-admin/ [R=301,L]

RewriteCond %{REQUEST_FILENAME} -f [OR]
RewriteCond %{REQUEST_FILENAME} -d
RewriteRule ^ - [L]
RewriteRule ^([_0-9a-zA-Z-]+/)?(wp-(content|admin|includes).*) $2 [L]
RewriteRule ^([_0-9a-zA-Z-]+/)?(.*\.php)$ $2 [L]
RewriteRule . index.php [L]

# Multisite

# END WordPress

Upvotes: 0

Views: 277

Answers (1)

Peter Wooster
Peter Wooster

Reputation: 6089

The first set of conditions cause anything that isn't an image, file or directory to go to the home.php front controller, this prevents them from being satisfied by the similar WordPress rules. You could add some more specific conditions to only pass certain pages to home.php or just remove that set of conditions and rules.

These two CMSs will not run well together, I'd put them on separate domains or subdomains.

Upvotes: 2

Related Questions