Skip to content

Instantly share code, notes, and snippets.

@ChrisDrit
Created December 23, 2020 18:21
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save ChrisDrit/00b00a8117346d864aa2b16a0e305a33 to your computer and use it in GitHub Desktop.
Save ChrisDrit/00b00a8117346d864aa2b16a0e305a33 to your computer and use it in GitHub Desktop.
var Webflow = Webflow || [];
Webflow.push(function() {
MemberStack.onReady.then(function(member) {
// handle the link click yourself
function triggerClick(event) {
event.preventDefault();
window.location.assign("https://website.com?id=" + member.id);
}
// replace this with the ID for
// your Webflow text link element
const myLink = document.getElementById('link-id');
// capture link click
myLink.addEventListener('click', triggerClick);
})
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment