Permalinks: Installed in different directory
-
I installed wordpress to the /wordpress directory. I then created a file motor.php for the WP motor to start and stop. In the files I create in the root directory, I do a php include to include the WP loop. My WP settings are as follows: My WP folder is set to http://www.foo.com/wordpress and the main index file is “../index.php” since I want WP to output the querystrings based on the root index.php file and not the “wordpress/index.php” file.
My question is this: How do I get about reconstructing .htaccess using the permalinks archive mod_con rewrite function to reflect this? I’ve tested the rule and it works beautifully if wordpress was installed into the root folder. However, how do I go about this if WP is installed 1 directory higher, and the website files being 1 directory lower?
/archives/%year%/%postname%/ gives me
RewriteEngine On
RewriteBase /wordpress/
RewriteRule ^archives/([0-9]{4})?/?([0-9a-z-]+)?/?([0-9]+)?/?$ /wordpress/index.php?year=$1&name=$2&page=$3 [QSA]
RewriteRule ^archives/category/?(.*) /wordpress/index.php?category_name=$1 [QSA]
Obviously I want WP permalinks to reflect the fact that the main index file is 1 directory lower. Please help! Thanks!
The topic ‘Permalinks: Installed in different directory’ is closed to new replies.