i used this tutorial and have everything set up like this in wix & sendgrid.
here is the code from the game review page.
// For full API documentation, including code examples, visit Velo API Reference - Wix.com
// sendgrid doctorfitztastic@gmail.com dinosaur!
import {sendEmail, sendEmailWithRecipient} from ‘backend/email’;
$w.onReady( function () {
$w(“#dataset1”).onAfterSave(sendFormData);
});
function sendFormData() {
const subject = Visitor Pinball Review **for** ${$w("#dropdown1").value}
;
const body = Game Review: \rName: ${$w("#input2").value} \rEmail: ${$w("#input1").value} \rPimball Game: ${$w("#dropdown1").value} \r \rAesthetics \rAesthetic Rating: ${$w("#radioGroup1").value} \rAesthetics Explanation: ${$w("#textBox1").value} \r \rDifficulty \rDifficulty Rating: ${$w("#radioGroup2").value} \rDifficulty Explanation: ${$w("#textBox2").value} \r \rGameplay \rGameplay Rating: ${$w("#radioGroup3").value} \rGameplay Explanation: ${$w("#textBox3").value} \r \rHistorical \rHistorical Rating: ${$w("#radioGroup4").value} \rHistorical Explanation: ${$w("#textBox4").value} \r \rOverall Review \rReview: ${$w("#textBox5").value}
;
const recipient = $w(“#input1”).value;
sendEmailWithRecipient(subject, body, recipient)
.then(response => console.log(response));
sendEmail(subject, body)
.then(response => console.log(response));
}
in the email i am only receiving part of the form submission.
-
Game Review:
-
Name: Testing
-
Email: xxx@gmail.com
-
Pinball Game: AC/DC
-
Aesthetics
-
Aesthetic Rating: 8 – AWESOME
-
Aesthetics Explanation: This is a test to see if you recieve the entire email.
-
Difficulty
-
Difficulty Rating: 8 – THIS ROCKS
-
Difficulty Explanation: I am going to rate everything with an 8 for no reason.
-
Gameplay
-
Gameplay Rating: 8 – OVERLY COMPLICATED
-
Gameplay Explanation: It
I think it might be punctuation. quotes and commas in the body of the form that is cutting off the response. is there a way to fix this?