6

I've mimicked Otto's setup here: http://ottopress.com/2011/creating-a-wordpress-site-using-svn/ and my brief example is below.

That tutorial is specific to a single site install, and specifies a single domain. How can I customize the htaccess below to be suitable for multisite? Note that the multisite htaccess WordPress provides doesn't work because the wp directory is custom.

Directory Setup

  • C:\wamp\www\my_site - Site root
  • C:\wamp\www\my_site\wp-config.php - Config
  • C:\wamp\www\my_site\wp - WordPress as an SVN external
  • C:\wamp\www\my_site\custom-content - Custom content dir

Apache Setup

<VirtualHost 127.0.0.1> ServerName example.com DocumentRoot "C:/wamp/www/my_site" ServerAdmin [email protected] <Directory C:/wamp/www/my_site> Order Allow,Deny Allow from all </Directory> </VirtualHost> 

htaccess

Options -Indexes RewriteEngine on RewriteCond %{HTTP_HOST} ^(www.)?example.com$ RewriteCond %{REQUEST_URI} !^/wp/ RewriteCond %{REQUEST_FILENAME} !-f RewriteCond %{REQUEST_FILENAME} !-d RewriteRule ^(.*)$ /wp/$1 RewriteCond %{HTTP_HOST} ^(www.)?example.com$ RewriteRule ^(/)?$ wp/index.php [L] 
3
  • why do you want wordpress in a custom dir /wp/?
    – janw
    CommentedApr 19, 2012 at 18:36
  • So that when I commit my project to SVN WordPress core files are totally independent of my plugins and themes. As an external I can switch WP versions on the fly.CommentedApr 19, 2012 at 19:08
  • do you switched 'wp-content' with 'custom-content' so that you store your themes,plugins,uploads there?
    – janw
    CommentedApr 19, 2012 at 20:49

2 Answers 2

2

For now, this is unsolvable according to Mark Jaquith, as noted here.

Q: Does this support WordPress in multisite mode?

A: No. Not until WordPress supports WordPress-in-a-subdirectory installation for multisite. If you're a WordPress hacker who wants to help with that feature, drop me a line

    1

    Not sure if this is exactly relevant, but Before You Create A Network: WordPress_Settings_Requirements says

    Giving WordPress its own directory will not work in WordPress 3.0 with multisite enabled. If you wish to install WordPress in a folder AND have that folder name it will work. Domain mapping, however, will not work.

    I'm not sure what AND have that folder name means there.

    1
    • I think this is referring to the situation where you might want example.com/wordpress/. In my case, I don't need/want the WordPress directory name public like that. I think my desired solution is reachable, but I just don't know enough about htaccess.CommentedMay 23, 2012 at 14:19

    Start asking to get answers

    Find the answer to your question by asking.

    Ask question

    Explore related questions

    See similar questions with these tags.