Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found
Not Found

Submitted

Newsletter-sign-up-form-with-success-message

@moritzrose

Desktop design screenshot for the Newsletter sign-up form with success message coding challenge

This is a solution for...

  • HTML
  • CSS
  • JS
2junior
View challenge

Design comparison


SolutionDesign

Solution retrospective


I definitely put in "required" for my email input, it worked yesterday...it doesn't work today...I didn't change a thing :D any help?

Community feedback

@nachospreafico

Posted

Hello!

I noticed 2 things in your code:

  • you used the required property twice in your input tag, might be causing the problem.
  • your label’s for attribute is not matching your input’s id.

On a side note, using HTML’s required attribute is super useful of course but you should try to add your own validations with JavaScript.

Hope this comment is helpful. Happy coding!

0

@mmxcrono

Posted

I see that you have type="submit" on the <form> tag instead of the <button> tag. The required flag on the <input> would be enforced by the browser if the form was being submitted, which should happen if the button was a submit type. I think that is the issue?

0

Please log in to post a comment

Log in with GitHub
Discord logo

Join 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