I randomly discovered that you could do this while optimising some of the code for our own community. I thought it was a good enough tip to share with all of you. If you’ve got any HTML element that you can freely control then wrap your link with the following code.
![](https://uploads-us-west-2.insided.com/gainsight-us/attachment/2938758f-83b3-4404-b4ad-c5ab82a77577.gif)
Triggering the modal to show at the login page:
<a class="loginmodal-link js-open-modal qa-register-have-account-link" data-modal="login" data-mn="ItemView" data-mn-app="frontend">Name of link here</a>
Triggering the modal to show at the registration page:
<a class="loginmodal-link js-open-modal qa-register-have-account-link" data-modal="register" data-mn="ItemView" data-mn-app="frontend">Name of link here</a>
Hope this helps!