FAQ: Learn HTML: Forms - Text Input

This community-built FAQ covers the “Text Input” exercise from the lesson “Learn HTML: Forms”.

Paths and Courses
This exercise can be found in the following Codecademy content:

Introduction to HTML

FAQs on the exercise Text Input

Join the Discussion. Help a fellow learner on their journey.

Ask or answer a question about this exercise by clicking reply (reply) below!

Agree with a comment or answer? Like (like) to up-vote the contribution!

Need broader help or resources? Head here.

Looking for motivation to keep learning? Join our wider discussions.

Learn more about how to use this guide.

Found a bug? Report it!

Have a question about your account or billing? Reach out to our customer support team!

None of the above? Find out where to ask other questions here!

1 Like

5 posts were split to a new topic: Old html bug

A post was split to a new topic: Is text the only value for type?

3 posts were split to a new topic: What’s the difference between the name and id attributes?

3 posts were split to a new topic: Why does input not require a closing tag?

2 posts were split to a new topic: What does the localhost username do?

4 posts were merged into an existing topic: Why does input not require a closing tag?

2 posts were split to a new topic: Can the value be overwritten?

3 posts were split to a new topic: How can I create a default value that disappears when the user types in the form?

2 posts were merged into an existing topic: What’s the difference between the name and id attributes?

Not sure if it’s okay to post non-questions here but I noticed once I added the “name” attribute with the “username” value and ran the code, my LastPass browser extension populated the option to try auto-filling the text field. Guess that means one way they determine which fields might need to be filled is by looking for certain values under the “name” attribute? Pretty neat!

the questions i am trying to do are right but the website is counting them wrong. Why is that?

I must be missing out on something, but what I don’t understand in this exercise is why you have to determine the value in the editor when it’s a form :
If I write another name than Davie in the editor, it comes out on the textfield alright, but shouldn’t it be the other way round, writing a different name on the webpage and seeing the value on the editor adapt to the change (for example) ?
I’m really confused about this, if anybody could enlighten me, it would be great :smiley:

The web page is raw text. Each time it loads it starts out the same way. The document served out is always the same. The only change made is in the DOM.

Thanks for such a quick answer ! :grinning:
I didn’t make myself clear : what if you have several users ? Isn’t there like a to-and-fro between the webpage and the DOM when it’s a form ?

1 Like

The DOM is on the client, so no matter how many users, they all have their own client.

1 Like

Aaaaaaah ! :zap: Thanks ! That’s what I was missing out.

1 Like