diff --git a/ccm-cms-assets-relatedlink/doc/freemarker/ccm-cms-assets-relatedlink.md b/ccm-cms-assets-relatedlink/doc/freemarker/ccm-cms-assets-relatedlink.md index 7a8da8fe0..5f5f7094c 100644 --- a/ccm-cms-assets-relatedlink/doc/freemarker/ccm-cms-assets-relatedlink.md +++ b/ccm-cms-assets-relatedlink/doc/freemarker/ccm-cms-assets-relatedlink.md @@ -1,109 +1,37 @@ -### ccm-cms-assets-relatedlink +# Freemarker functions for related links + +Import path +: `/ccm-cms-assets-relatedlinks` Functions for processing the related links assigned to a content item. -#### getRelatedLinks +## `getRelatedLinks(item: Node, linkListName: String = "NONE"): Sequence` - getRelatedLinks(item, linkListName="NONE") +Retrieves the related links assigned to a content item. Related links can be organized in named list. The optional parameters `linkListName` controls which list is used. If the parameter is omitted the default value `NONE` is used. -Retrieves the related links assigned to a content item. - -##### Parameters - -`item` The content item - -`linkListName` The related links of a content item can be organized in -link lists. The default list (if no other is used) is `NONE` which is -the default value of this parameter. Only the links which belong to the -provided group are returned. - -##### Returns - -The related links of the provided `linkListGroup` of the provided content -item. - -#### getLinkType - - getLinkType(link) +## `getLinkType(link: Node): String` Gets the type of the provided link which can either be `externalLink`, `internalLink` or `caption`. -##### Parameters - -`link` The link - -##### Returns - -The type of the provided link. - -#### getLinkTitle - - getLinkTitle(link) +## `getLinkTitle(link: Node): String` Gets the title of the provided link. -##### Parameters - -`link` The link. - -##### Returns - -The title of the provided link. - -#### getLinkDescription - - getLinkDescription(link) +## `getLinkDescription(link: Node): String` Gets the description of the provided link. -##### Parameters +## `getLinkOrder(link: Node): String` -`link` The link. +Gets the order value for the provided link. -##### Returns +## `getInternalLinkParameters(link: Node): String` -The description of the provided link. +Gets the URL parameters of the of the provided link (The part after +the question mark). -#### getLinkOrder - - getLinkOrder(link) - -Gets the order value of the provided link. - -##### Parameters - -`link` The link. - -##### Returns - -The order value of the provided link. - -#### getInternalLinkParameters - - getLinkInternalLinkParameters(link) - -Gets the parameters of the of the provided link. - -##### Parameters - -`link` The link. - -##### Returns - -The parameters to add to the URL of the provided link. - -#### getTargetUri - - getTargetUri(link) +## `getTargetUri(link: Node`): String Gets the URI of the target of the provided link. -##### Parameters - -`link` The link. - -##### Returns - -The URI of the target of the provided link. -