Take the 2-minute tour ×
WordPress Development Stack Exchange is a question and answer site for WordPress developers and administrators. It's 100% free, no registration required.

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 me@example.com

    <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]
share|improve this question
    
why do you want wordpress in a custom dir /wp/? –  janw Apr 19 '12 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. –  developdaly Apr 19 '12 at 19:08
    
do you switched 'wp-content' with 'custom-content' so that you store your themes,plugins,uploads there? –  janw Apr 19 '12 at 20:49

2 Answers 2

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.

share|improve this answer
    
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. –  developdaly May 23 '12 at 14:19
up vote 2 down vote accepted

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

share|improve this answer

Your Answer

 
discard

By posting your answer, you agree to the privacy policy and terms of service.

Not the answer you're looking for? Browse other questions tagged or ask your own question.