This article does not apply to Umbraco 8.

    The concepts and code in this article have been deprecated in Umbraco 8 and no longer apply.
    If you are using Umbraco 7, this article is perfect for you!

    Related Links

    Returns: RelatedLinks

    Related Links allows an editor to add an array of links. These can either be internal Umbraco pages or external URLs.

    This property has been replaced by Multi URL Picker in Umbraco 8.

    Data Type Definition Example

    Related Links Data Type Definition

    Content Example

    Media Picker Content

    MVC View Example - value converters enabled

    The RelatedLinks do not work without Umbraco.Web.Models. Don't forget to use it.

    Typed

    @using Umbraco.Web.Models
    @{
        var typedRelatedLinksConverted = Model.Content.GetPropertyValue<RelatedLinks>("footerLinks");
    
        if (typedRelatedLinksConverted.Any())
        {
            <ul>
                @foreach (var item in typedRelatedLinksConverted)
                {
                    var linkTarget = (item.NewWindow) ? "_blank" : null;
                    <li><a href="@item.Link" target="@linkTarget">@item.Caption</a></li>
                }
            </ul>
        }
    }