11-17-2023, 07:59 PM
(11-17-2023, 03:28 PM)misproductions Wrote: hey is there a way you can hide and show certain dom elements (i know in js and jquery using hide show etc) ?
also how would I implement the onChange event for each question so that i can print
a message based on the selected answer
Hey @misproductions, I've updated the sample to show you how to show and hide the dom elements. I've also added a change event to the favorite color option list.
Generally speaking, any dom element object that is set from either the Dom.Create or Dom.Get methods has all of the style properties that can be set in Javascript. And there are a lot now! Here's a handy reference:
https://www.w3schools.com/jsref/dom_obj_style.asp
Similarly, you can create event handler methods for every type of event (that the element supports) with the Dom.Event method. Here's a reference of all the available events:
https://www.w3schools.com/jsref/dom_obj_event.asp