title: IIS challenge: Setup for global and localization sites (with geolocation) under single domain
body: <p>I need help solving a IIS configuration "puzzle". Here's what I have:</p>
  
  <p><strong>1 Domain:</strong> example.com</p>
  
  <p><strong>4 Web folders:</strong> </p>
  
  <ul>
  <li>[root]\Global - single page HTML site </li>
  <li>[root]\Classic1 - classic ASP site</li>
  <li>[root]\Classic2 - .Net 2.0 site</li>
  <li>[root]\Redesign - .Net 4.0 site with geolocation</li>
  </ul>
  
  <p>Windows Server 2008 R2 with IIS 7</p>
  
  <p><strong>Background</strong></p>
  
  <p><em>example.com</em> is a website that has localized sites by country. Meaning <em>example.com/us</em> is for US users, <em>example.com/uk</em> is for European users, <em>example.com/AU</em> for Australian users, etc. </p>
  
  <p>There are a total of 20 different country sites for <em>example.com</em>, where <em>example.com</em> has a single landing page with an index of country links.</p>
  
  <p><strong>Objectives</strong></p>
  
  <p><em>Redesign</em> is a new site developed that is supposed to take over everything so we can get rid of the other 3 sites. It has localization with geolocation on the landing page that will determine which set of country-specific data to show on the website. Based on the country detected, it will rewrite the URL by appending the country code to the URL, like <em>example.com/au</em>.</p>
  
  <p>However, I am tasked to launch <em>Redesign</em> only a few countries at a time because the data entry people need time to setup each country.</p>
  
  <p>This is what needs to happen for now:</p>
  
  <ul>
  <li>example.com => [root]\Global </li>
  <li>example.com\uk => [root]\Classic1 </li>
  <li>example.com\us => [root]\Classic2  </li>
  <li>example.com\au => [root]\Redesign </li>
  <li>example.com\xx => [root]\Classic1</li>
  </ul>
  
  <p>... and so forth.</p>
  
  <p><strong>Problem</strong></p>
  
  <p>First I created a site in IIS that points to [root]\Global.</p>
  
  <p>Then I created a virtual directory for each country and have each points to the appropriate directory.</p>
  
  <p>However, because <em>Redesign</em> has geolocation, it automatically rewrite the URL as:
  example.com\au => example.com\au\us</p>
  
  <p>Now, if I set <em>Redesign</em> as the global site and then the other classic sites as virtual directory, the geolocation will be in conflict with the virtual directory paths:</p>
  
  <ul>
  <li>example.com\us =? [root]\Redesign  </li>
  <li>example.com\us =? [root]\Classic2</li>
  </ul>
  
  <p>This is where I'm stuck. Anyone has any feedback and suggestions?</p>