vBulletin / Wordpress htaccess collision - Help!

Discussion in 'vBulletin Discussions' started by Dan Hutter, Jan 9, 2012.

  1. Dan Hutter

    Dan Hutter aka Big Dan

    Joined:
    Jul 20, 2006
    Messages:
    1,412
    Likes Received:
    515
    Location:
    New York
    Hey Guys,

    I'm working with a site that has Wordpress at domain.com and vB 4 at domain.com/forums. Everything works okay as far as thread viewing and such with mod rewritten URLs in both WP and vB. Until you use a vBulletin script that passes a variable in the URL. For instance domain.com/forums/search.php?do=getnew spits out a WP 404. Search.php is physically on the server and works if I temporarily remove WP's htaccess so there's a collision there. Is there a way I can just tell WP's htaccess to ignore /forums/?

    I've seen people run vB 4 as a subfolder of a WP site before so it's possible. I just don't know what to change. Any ideas? Thanks.

    Here's WP's htaccess

    Code:
     
    # 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
    
    Here's vB's htaccess
    Code:
    RewriteEngine on
    # If you are having problems or are using VirtualDocumentRoot, uncomment this line and set it to your vBulletin directory.
    RewriteBase /forums/
    # If you are having problems with the rewrite from content/ to content.php, uncomment this line to turn MultiViews off.
    # Options -MultiViews
    RewriteCond %{REQUEST_FILENAME} -f [OR]
    RewriteCond %{REQUEST_FILENAME} -l [OR]
    RewriteCond %{REQUEST_FILENAME} -d
    RewriteRule ^.*$ - [NC,L]
    # Forum
    RewriteRule ^threads/.* showthread.php [QSA]
    RewriteRule ^forums/.* forumdisplay.php [QSA]
    RewriteRule ^members/.* member.php [QSA]
    RewriteRule ^blogs/.* blog.php [QSA]
    RewriteRule ^entries/.* entry.php [QSA]
    RewriteCond %{REQUEST_FILENAME} -f [OR]
    RewriteCond %{REQUEST_FILENAME} -l [OR]
    RewriteCond %{REQUEST_FILENAME} -d
    RewriteRule ^.*$ - [NC,L]
    # MVC
    RewriteRule ^(?:(.*?)(?:/|$))(.*|$)$ $1.php?r=$2 [QSA]
    # Check MVC result
    RewriteCond %{REQUEST_FILENAME} -f
    RewriteRule ^(.*)$ - [NC,L]
    RewriteRule ^(.*)$ - [R=404,L]
    
     
  2. Brandon

    Brandon Regular Member

    Joined:
    Jun 1, 2009
    Messages:
    6,602
    Likes Received:
    1,706
    Location:
    Topeka, Kansas
    First Name:
    Brandon
    Did you ever get this working?
    if so, what was it?

    Thanks
     
  3. Dan Hutter

    Dan Hutter aka Big Dan

    Joined:
    Jul 20, 2006
    Messages:
    1,412
    Likes Received:
    515
    Location:
    New York
    I did. I forget what I did though. I'm lucky if I remember what I had for breakfast this morning. :)

    I probably took the easy route and moved the forum to a subdomain.
     
    Brandon likes this.
  4. Brandon

    Brandon Regular Member

    Joined:
    Jun 1, 2009
    Messages:
    6,602
    Likes Received:
    1,706
    Location:
    Topeka, Kansas
    First Name:
    Brandon
    :ROFL:
    I hear ya
     
    Dan Hutter likes this.

Share This Page