Back to the Shapespark home page

Customization of navigation menu button

does anyone know if there is a way to make a navigation menu button a trigger for a URL

Adding a button to the view list might be tricky. Would a button in the bottom right corner work for you? If so, copy the button icon to extra-assets subdirectory of the scene directory (in Documents\Shapespark) add the following body-end.html file in the scene directory:

<script>
  var viewer = WALK.getViewer();
  var button = viewer.addMenuButton('$EXTRA_ASSETS/name-of-the-icon-file');
  button.addEventListener('click', function() { viewer.openUrl('https://url-to-open'); });
</script>

replacing name-of-the-icon-file and url-to-open with appropriate values.