Design comparison
Solution retrospective
Hi All
Anyone willing to assist me with an issue, I couldn't seem to get the user email address to pull through to the thank you page. Any feedback will be appreciated.
Community feedback
- @TomasPereira-DevPosted 12 months ago
hey, what's up!, I'm not sure 100% if this might be the problem, but try changing the regex to this one:
const regex = [-A-Za-z0-9!#$%&'*+/=?^_`{|}~]+(?:\.[-A-Za-z0-9!#$%&'*+/=?^_`{|}~]+)*@(?:[A-Za-z0-9](?:[-A-Za-z0-9]*[A-Za-z0-9])?\.)+[A-Za-z0-9](?:[-A-Za-z0-9]*[A-Za-z0-9])?
I used a regex generator for this because most of the time I try to write one by myself it end up with bugs, those are a pain to be honest, lol. Good Luck!Marked as helpful0 - @redstar504Posted 12 months ago
Hey, great job! For the purposes of the demo, you may consider using Javascript's local storage property. Simply write the email to the storage when the form is submitted and retrieve from storage on the success page. I actually just finished the same challenge, and forgot about this step, so I will be implementing it in my example using this technique!
Marked as helpful0 - @huzaifa-21Posted 12 months ago
just throw the input.value in the message when you submit the form
0
Please log in to post a comment
Log in with GitHubJoin our Discord community
Join thousands of Frontend Mentor community members taking the challenges, sharing resources, helping each other, and chatting about all things front-end!
Join our Discord