Hello everyone,
I have few inputs in my website, and some of them are filled in automatically depending on the user’s answers in previous inputs. For example, if the user chose the first option in a drop down menu, then the answer to the next question (input) would be completed automatically.
This is the code:
export function dropdown_change(event) {
let value = $w(“#dropdown”).value;
if (value === “Dog”) {
$w(‘#input1’).value = $w(‘#text1’).text;
} else {
$w(‘#input1’).value = $w(‘#text2’).text;
}
}
text1 and text2 are text elements which are connected to the database and updated in accordance with the user’s answer to previous questions. As can be seen above, I want them to fill in input1.
After deploying that code, the inputs are actually completed automatically. However, the information is not sent to the database. Why is that?
Thanks a lot
Tal