PP.Ui.Hyperlink (settings)
settings. JSON object that contains values of component properties.
The Hyperlink constructor creates an instance of the Hyperlink component.
To execute the example, in the HEAD tag add links to PP.js library and to PP.css visual styles. To place the component, add a DIV element with the identifier hyperlink to the page. In the SCRIPT tag add component creation code:
var settings = { Content: "Load the next 100 records...", ParentNode: document.getElementById("hyperlink") }; var hyperLink = new PP.Ui.Hyperlink(settings); hyperLink.Click.add(function (sender, args) { console.log("Go to the hyperlink"); console.log(sender.getContent()); });
After executing the example a hyperlink that looks as follows appears in the page:
On clicking a hyperlink the browser console displays the Follow the Hyperlink message and hyperlink text.
See also: