Select the other related page on the right side of the relationship (type the alias path or click Select page).

Click Save.

The two pages are now related. The relationships are not symmetric — each relationship has one of the pages on the left side and the other on the right. You can add any number of relationships to pages.

Note that creating and removing relationships between pages is not a versioned operation. That is, changes to the relationships are immediately reflected on the published version of the pages.

Displaying related pages using web parts

On portal engine pages, you can display related pages using listing web parts. Web parts that support relationships have the following properties available in the Relationships category:

Page relationship properties (Web parts)

Description

Main page

Allows you to configure the web part to display only related pages:

Display pages related to the current page - pages related to the page that contains the web part.

Display pages related to the page with NodeGUID - pages related to the page with the specified Node GUID identifier. You can find the Node GUID of pages on the Properties -> General tab of the Pages application.

Main page is on the left side

Determines whether the specified page (Main page) is on the left or right side of the relationship.

If checked, the web part displays pages on the right side of the relationship.

If disabled, the web part displays pages on the left side of the relationship.

Relationship name

The web part uses the selected page relationship type.

Note: The relationship properties do not ensure that web parts load all pages belonging to the specified relationship — they only filter the source data. You still need to set the remaining data source properties to load the required pages (such as the Path).

Example

The following example shows how to display news items related to a product using the Repeater web part. The example assumes you are using the sample Corporate site.

Open the Pages application and select the sample Corporate site.

Select the /Products/Laptops-and-Tables/Apple iPad2 page and add a relationship (is related to) with the /News/Apple-iPad2-In-Stock page.

Switch to Apple iPad2 page's Design tab and add a Repeater web part to Main zone.

Configure the following properties for the Repeater:

Path: /% (displays related news items from the whole website)

Page types: CMS.News

Transformation: CMS.News.Preview

Relationships -> Main page: Display pages related to the current page

Relationships -> Main page is on the left side: yes (checked)

Relationships -> Relationship name: is related to

HTML Envelope -> Content before: <h3>Related news:</h3>

Save & Close.

The page now displays a preview of the news items related to the product.

Displaying pages using controls

Use controls to display related pages on ASPX page templates or in the code of custom components. The following controls support displaying of related pages: