Linking a text to a particular location

Hi Err’body,

I trust you’re having a lovely day so far :slight_smile:

May you kindly please assist.

Problem Statement: To finish this fieldset off, link the text terms and conditions in the third label to the following location:

https://www.freecodecamp.org/news/terms-of-service/

My solution:

<fieldset>
        <label for="personal-account"><input id="personal-account" type="radio" name="account-type" /> Personal Account</label>
        <label for="business-account"><input id="business-account" type="radio" name="account-type" /> Business Account</label>
        <label for="terms-and-conditions"><input id="terms-and-conditions" type="checkbox" required /> I accept <a href="https://www.freecodecamp.org/news/terms-of-service/" >the terms and conditions</a></label>
      </fieldset>

Link to challenge:

Learn HTML Forms by Building a Registration Form: Step 30 | freeCodeCamp.org

:pray:t6:

Don’t wrap the anchor tag around the word: the
It should be outside the tag as it is not part of the link.

Hi there :wave:t6: :slight_smile:

I see my mistake.

You mean like this:

   <fieldset>
        <label for="personal-account"><input id="personal-account" type="radio" name="account-type" /> Personal Account</label>
        <label for="business-account"><input id="business-account" type="radio" name="account-type" /> Business Account</label>
        <label for="terms-and-conditions"><input id="terms-and-conditions" type="checkbox" required /> I accept the <a href="https://www.freecodecamp.org/news/terms-of-service/"> terms and conditions </a></label>
      </fieldset>

Still results in an error though :frowning:

Now you have too many spaces. The linked text should be the exact three words with no extra spaces

1 Like

You were right :sweat_smile:

Cracked it!

Appreciated :pray:t6:

1 Like

This topic was automatically closed 182 days after the last reply. New replies are no longer allowed.