CodeGarden 10: The sixth annual Umbraco Developer Conference
June 23-25th 2010 - free ASP.NET MVC pre-conference. Register today!

Running multiple websites on one Umbraco installation

Pages

Setting up your nodes

First, you create the websites under your Content node.

Then, you assign the proper hostnames to each website by right-clicking on the website node and selecting Manage Hostnames.

For english language sites, just select english from the Language drop-down menu.
If you want to have multilanguage sites, you need to first add the languages in the Settings section of umbraco and then choose the corresponding language in the Language drop-down menu.
Then you can use dictionary items on your page.

 

Setting up Umbraco

Make sure that your umbracoSettings.config (located inside your config folder)
has the following setting:

<useDomainPrefixes>true</useDomainPrefixes>

 

Setting up IIS

If you don’t have your own server, but are using a hosting provider, you have to get them to do the following changes.

IIS 6

Right-click your application and select Properties.
Go to the Web Site tab and click on Advanced in the Web Site Identification section.
Then add the domains you want umbraco to use in your umbraco installation.

IIS 7

Right-click your application and select Edit Bindings.
Then add the domains you want umbraco to use in your umbraco installation.

 

(Optional) Using Templates and Document Types

You have to create different templates for every site you have.

That means, you will most probably not be able to use the same master template for several sites.
Although you can use the same document type across several sites.

In those cases where you don’t use a master template (for example a google sitemap template), you are able to use only one template across all your sites.

My advice is to create a child under your Document Type specific to a website.

e.g:

List Articles
    |_    Website 1
    |_    Website 2
Article
    |_    Website 1
    |_    Website 2

Then assign your site-specific template to the Website 1 (or Website 2) Document Types.