on line 8 it should be
let emails = [];
it’s a open and close box bracket
the error was in line 13 you can’t use .push for a string
It works only for the array [ ]
That’s why the whole code after line 13 is not executing
Would you please show me the working code in full to compare?
@killam1586
Code
import wixUsers from 'wix-users';
import wixData from 'wix-data';
import wixLocation from 'wix-location';
$w.onReady(function () {
$w('#submit').onClick(() => {
let emails=[];
let name = $w("#name").value;
let phone = $w("#phone").value;
let address = $w("#address").value;
emails.push($w('#email').value);
wixUsers.register($w('#email').value, $w('#password').value, {
"contactInfo": { name, emails, phone, address}
}).catch(err =>console.log(err));
}
);
});
@salman-hammed SUCCESS!!!
Thank you dearly! You have been amazingly helpful. =D
@killam1586 Awesome!
Your welcome