Dear all,
I’d lie the input fields to show the content that has already been entered by the user.
To be specific, I’m talking about a user page. The user enters data, that then is send and stored in a database. When the user wants to change some of his data (e.g. location etc.), he then goes back to this page. It’ll be nice if the input fields then show his content, so he can change it.
I know how to send/store data to the database. I know how to retrieve and show this data. However, with the functionality in WIX I can only to one of those things at a time.
$w.onReady(function () {
const fullName = local.getItem('title');
const about = local.getItem('price');
const referralCode = local.getItem('class');
const teslaModel = local.getItem('days');
const latitude = local.getItem('days');
const longitude = local.getItem('days');
$w('#input1').value = fullName;
$w('#input2').value = about;
$w('#dropdown1').value = referralCode;
$w('#location').value = teslaModel;
$w('#latitude').value = latitude;
$w('#longitude').value = longitude;
});
I tried to apply the following corvid code to show the values already entered, but no change is shown to before. Does anyone have an idea on that?
Many thanks,
Constantin
PS: Currently, the input fields now would overwrite the entire content, when resumitting data. Meaning, those input fields that are left blank erase the previously added content,