Debug a Donation Form - Debug a Donation Form

Tell us what’s happening:

Debug a Donation Form: 11. You should associate every input element with a label element using the for and id attributes.

I’m unable to see why I can’t pass this part of the debugging workshop - please help.

Your code so far

<!DOCTYPE html>
<html lang="en">
<head>
  <meta charset="UTF-8">
  <title>Donation Form</title>
</head>
<body>
  <h1>Donation Form</h1>
  <form>
    
    <label for="fullName" id ="fullName">Full Name:</label>
    <input id ="fullName" type="text" name="name" required>

    <label for="emailAddress" id="emailAddress">Email Address:</label>
    <input id="emailAddress" type="email" name="email" required>

    <label for="donatinAmount" id="donationAmount">Donation Amount ($):</label>
    <input id="donationAmount" type="number" name="amount" required>

    <label for="newsLetter" id="newsLetter">Subscribe</label>
    <input id="newsLetter" type="checkbox" name="newsletter">
    Subscribe
    
    <label for="submit" id="submit">Submit</label>
    <input type="submit" value="Send">
  </form>
</body>
</html>

Your browser information:

User Agent is: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/18.3 Safari/605.1.15

Challenge Information:

Debug a Donation Form - Debug a Donation Form

There is a typo too in one of your Label Id.
And the word “Subscribe” appears twice in the code.

Also, I try to pass test 3. but no luck.

3. You should have exactly four label elements in your form.

An id must be unique. You cannot use the same id for more than one element.

You have 5 label elements, not 4 labels as stated in failed Test #3. The input element with type=“submit” does not actually accept user input.

Test 3. - I have found out, the user stories doesn´t require you to make a Label for the submit button.

you can’t give the same id to multiple elements

You should remove the id from the label, and make sure the id is on the input element and matches the name attribute.