Learn Form Validation by Building a Calorie Counter - Step 47

Tell us what’s happening:

Hi there

Anyone know what I am missing please

Thanks
Iskren

Your code so far

<!-- file: index.html -->

/* file: styles.css */

/* file: script.js */
// User Editable Region

  const HTMLString = `<label for="${entryDropdown.value}-${entryNumber.value}-name">Entry ${entryNumber} Name</label>`;

// User Editable Region

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/17.4.1 Safari/605.1.15

Challenge Information:

Learn Form Validation by Building a Calorie Counter - Step 47

Hello @iskren500 !

Good attempt!

  const HTMLString = `<label for="${entryDropdown.value}-${entryNumber.value}-name">Entry ${entryNumber} Name</label>`;

Please remove the for attribute and content from the opening label tag?

There should only be an opening label tag and a closing label tag with the text as you have entered it here.

Example: 
<label>text</label>

Wishing you good progress on your coding journey. :slightly_smiling_face:

Like this? its still not working

const HTMLString = <label>`Entry ${entryNumber} Name`</label>;

}

can you help please?

Hi there!

You should not have template literal strings (back ticks) within the label , around the label text.

Hello @iskren500 !

Good attempt.

It should only have the text

between the opening and closing label tags, nothing else is required.
Please do not enclose it in a template literal?

Just as you have the text, only, between the labels.

Keep up the good progress and I wish you much more success on your coding journey. :slightly_smiling_face: