Create an Anchor Link Button
Please note that this is now available as a plugin for easier installation. While you can use this document as a reference, the recommended method to add this functionality is through the plugin installation wizard. Learn more about plugins here.
This is a way to create a button that goes to the row you would like your page to scroll to.
Step 1
Add an HTML component, and within the source code <> create a button with the class of anchorButton.
You can change the class and phrase "Go!" to your liking.
<p><button class="anchorButton">Go!</button></p>
Step 2
On your live app, find the Row that will be your anchor - the row you want the page to scroll to.
Step 3
Add this code to the JavaScript tab of your page.
Replace ‘x_element_page_10_5’ with the ID of your row.
$(".anchorButton").click(function() {
$('html, body').animate({
scrollTop: $("#x_element_page_10_5").offset().top
}, 750);
});
We'd love to hear your feedback.