Welcome to the Treehouse Community
Want to collaborate on code errors? Have bugs you need feedback on? Looking for an extra set of eyes on your latest project? Get support with fellow developers, designers, and programmers of all backgrounds and skill levels here with the Treehouse Community!
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and join thousands of Treehouse students and alumni in the community today.Start your free trial
I don't understand what this question is asking for me to do. I've gotten it wrong 2 times. Please give me more hints.
HTML Section Mastery Challenge Question: Set that text input to contain "Hello World"
<!DOCTYPE html> <html> <head> <title>HTML Mastery Challenge</title> </head> <body> <h1>HTML Mastery Challenge</h1> <!-- Write your code below --> <div> <h2>Shopping List</h2> <ol> <li>carrots</li> <li>apples</li> <li>bread</li> </ol> </div> <p><strong>Things to buy</strong></p> <form action="#" method="POST" name="my_form"> <input type="text" name"username"><br> <input type="password" name"password"><br> <textarea name="essay" row="10" cols="30"></textarea><br> <input type="submit"value="Hello World"> </body> </html>
Daniel Gauthier15,000 Points
Taking a look at your code, there are three issues that will cause problems.
The first issue is that you didn't include the = sign after the name attribute in the first two input elements in your form.
The second issue is that you didn't close your form tag with a closing form tag.
The third issue is that the challenge is asking you to set the text input to read "Hello World", which can be accomplished by adding a 'value' attribute to the input element with the type text, and assigning the value of the 'value' attribute to be "Hello World".
When completed, the result will look like Ashish Mehra's provided answer.
I just wanted to add some clarification about what appeared to be wrong in your answer.