URL rewrite issues with WordPress in a subdirectory

So to me to this sounded like a simple a request. i have a main site:

www.mainsite.com

Read More

A wordpress install that contains a couple new sections for the site in a subdir:

www.mainsite.com/wp

The need is to remove the wordpress directory name from certain URLs/wordpress pages.
so:

www.mainsite.com/wp/press
needs to be:
www.mainsite.com/press

I’m quite the Apache noob my rewrite rules keep giving errors in the browser whether its 404 or redirect loop errors.

so under my document root in http.conf i have:

RewriteRule ^press/?$ mysite.com/wp/press-room

I know this is probably the completely wrong approach for a rule , but as I said I’m not an Apache guy any help would be GREATLY appreciated just to steer my mind in the right direction.

Related posts

Leave a Reply

2 comments

  1. So I finally got this working, it was just a matter formatting redirect URL so wordpress likes it.

    So in my root htaccess file : for this url mysite.com/careers

    RewriteRule ^careers/?$ wp/index.php?pagename=careers [L]

    And voila and it started working just fine.