I was trying to do this very thing and could not get .htaccess rules to behave for anything but the subdirectory I wanted to exclude. Requests to '/careers/' would load my sub-site, but '/careers/photo-gallery' would be handled by the containing sited.
Context: I inherited a Wordpress multisite and was contracted to build a careers subsite that described company culture and interfaced with a 3rd party recruiting solution. I built a test site and migrated that to a subdirectory on the main site once it was approved.
Ultimately, I modified the index.php of the containing site so it looks like this:
<?php
/**
* Front to the WordPress application. This file doesn't do anything,
* but loads
* wp-blog-header.php which does and tells WordPress to load the
* theme.
*
* @package WordPress
*/
if (strpos($_SERVER['REQUEST_URI'], "/careers") === 0)
{
require (dirname(__FILE__) . '/careers/index.php');
}
else
{
/**
* Tells WordPress to load the WordPress theme and output it.
*
* @var bool
*/
define('WP_USE_THEMES', true);
/** Loads the WordPress Environment and Template */
require( dirname( __FILE__ ) . '/wp-blog-header.php' );
}
Yes, I feel like I'm doing it wrong, but that feels better than the hours I lost trying to figure out why rewrite rules weren't behaving as I expected.