The best way to use forms...

Thanks. The first problem is solved now trying to work through the second. I would like to send a triggered email from the code. I have the triggered email set up ‘Quoteemail’. I have tried hard coding an email address in and using the email from the email input form (#email). I haven’t got anything to work (in the code below ContactId isn’t defined). I’ve tried to create a contact to facilitate the sending of an email, but I’m getting nowhere. Any ideas on what I’m doing wrong?

Thanks,

Phil

export function myBackendFunction() {
wixCrm.createContact({
“firstName” : $w( ‘#name’ ).value,
“email” : $w( ‘#email’ ).value,

})

}

wixCrm.emailContact( "Quoteemail" , ContactId, { 

“variables” : {
“vfirstName” : $w( ‘#name’ ).value,
“vSensors” : $w( ‘#sensors’ ).value,
“vAdditionalUsers” : $w( ‘#users’ ).value,
“vAdditionalData” : $w( ‘#additionalData’ ).value,
“vIOPS” : $w( ‘#additionalActions’ ).value,
“vTotalPrice” : “Total Price” ,
“vUserLimit” : “User Limit” ,
“vIOPSLimit” : “Action Limit” ,
“vDataLimit” : “Data Limits”
}}
)