addLink()

The addLink() function (client-side) adds a clickable URL to the Link section on the product interface to let users access external resources.

Note:

To view the links on the product interface, check the Display link container box on the product record.

Syntax

Use this syntax for the addLink() function:

            addLink('URL', 'label'); 

          

Parameters

Note:

All parameters are required.

  • URL (string) - The URL for the web resource. The function accepts both the format with the protocol ("https://www.oracle.com") or without it ("www.oracle.com").

    Note:

    If two URL strings exactly match, the link will be added only one time. For example, "https://www.oracle.com" and "www.oracle.com" are considered as different strings.

  • label (string) - The label that will appear as the clickable text for the URL.

Examples

The following examples show how to use the addLink() function.

Adding a Link to the Product Interface

This example adds a link labeled 'Visit Website' that takes users to https://www.oracle.com.

              addLink('https://www.oracle.com', 'Visit Website'); 

            

Related Topics

General Notices