Sets or gets the dashboard text button's link.
When the dashboard text button is clicked, the browser navigates to the link location.
You can set link to any of the following:
The link property attempts to properly encode the URL value that you set. For example, .../some page is encoded to .../some%20page. However, some URLs do not have one unambiguous encoding. In those cases it is up to you to encode the URL to reflect your intentions. Because of these situations, it is a best practice to always encode URLs before you set them as the value of the link property. Regardless of how you set the link property, when you get its value, it returns an encoded URL.
Note that Wix URLs do not contain spaces. A page which has spaces in its name has its spaces replaced with dashes (-). Similarly, a dynamic page URL which contains the value of a field in your collection with spaces has its spaces replaced with dashes (-).
Note: Make sure to set your button link before running (and not inside) the onClick() event handler.