Configuring site resolving logic in multisite solutions


Site Resolving Settings

The article describes configuration settings related to site resolving functionality and some scenarios related to the Preview and Editing mode, when they are relevant.

Sometimes site resolving logic might seem to work in unexpected ways (for example, when opening items in the Experience Editor or in the Preview mode), but in fact the behavior is affected by special configuration settings that can be changed according to your requirements.

There are several settings that help to configure proper site resolving logic in multisite solutions:

A detailed description of each setting can be found in the following configuration file:

Use Case Scenarios

In general, we recommend you keep the Rendering.SiteResolving setting value being set to "true" for any multisite solution in order to ensure that cross-site links are built with the correct parameters. In this case, the Experience Editor and the Preview mode are opened in the context of the site defined in the Preview.DefaultSite setting if no other site can be resolved.

To make sure that items are opened in the context of the correct site, it is required to set the Rendering.SiteResolvingMatchCurrentSite setting to "true."

There might be a case when the Rendering.SiteResolvingMatchCurrentLanguage setting is set to "true", and a specific site definition node (located under the <sites> node) has a language parameter. In this scenario, if a user opens the Experience Editor or the Preview mode, the site is resolved according to the specified language parameter. For example, there are two sites configured with "site" and "altSite" names. The Preview.DefaultSite setting value is "site", and the language parameter value of the "altSite" node is "de". In this case, the following scenarios are possible:

To avoid this behavior, the Rendering.SiteResolvingMatchCurrentLanguage setting can be set to "false." Overall, in most cases, this setting can be set to "false" unless several site definitions differ only by the language parameter. For example, if there are two sites that use the same items and site roots but different hostnames (uk.hostname and de.hostname). In this case, site resolving is language-sensitive, and the Link Provider will take the language parameter into consideration, and therefore the setting should be set to "true."