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! While you're at it, check out some resources Treehouse students have shared here.

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

HTML

HTML form

Why my label text isn't ok? It should be to stay above input field but it doesn't.

    <h3>Touch with us here</h3>
    <label for="mail">Email:</label><br>
    <input type="mail" id="mail" name="user_mail">
    <label for="password">Password:</label><br>
    <input type="password" id="password" name="user_password">
    <label for="bio">About you:</label><br>
    <textarea id="bio" name="user_bio"></textarea>





    </form>
    ```

2 Answers

Hi there,

You will need to place the line break tags <br> on the end of each input and label tag like the below:

<div id="message" align="center"></div>
<div id="example"></div>
<h3>Touch with us here</h3>

<label for="mail">Email:</label><br>
<input type="mail" id="mail" name="user_mail"><br>

<label for="password">Password:</label><br>
<input type="password" id="password" name="user_password"><br>

<label for="bio">About you:</label><br>
<textarea id="bio" name="user_bio"></textarea><br>

Thanks, Bradley.

Thanks Bradely, I already solve this, I put label { display: block; } so they use full width, they're inline elements by default so there was problem, but I will check your method too.

Regards

You need more page break tags, after your input fields. Right now you only have <br> tags after the labels, so the page isn't breaking after the input fields.

<form>
    <h3>Touch with us here</h3>
    <label for="mail">Email:</label><br>
    <input type="mail" id="mail" name="user_mail"><br>
    <label for="password">Password:</label><br>
    <input type="password" id="password" name="user_password"><br>
    <label for="bio">About you:</label><br>
    <textarea id="bio" name="user_bio"></textarea>
</form>