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 Forms Inputs

Code looks different in browser to what is being displayed in video

My code is identical however when I open my html file in Chrome I get something different than to what is displayed in the video. Characters are not hidden in the password field and instead of buttons which can be selected I get two text fields where text can be entered where it says "male" and "female" next to them. Any idea why this could be???

5 Answers

OK Jack, I got it. I copied your code to my sublime and it seems to be the quotes that you are using to wrap the type, name and everything in your code. The right quotes to use is this one: ". Try to copy it and paste in your code. From here probably you will be able to find the properly one on your keyboard. Test it and let me know.

Yep that was it, thanks a lot Pedro I never would've noticed it!

Hey Jack, can you paste your code here ? Then would be easier to help you. Thanks. ;)

<form action=”#” method=”POST” name=”my_form”>
<input type=”text” name=”username”><br>
<input type=”password” name=”password”><br>
<input type=”radio” name=”gender” value="Male">Male<br>
<input type=”radio” name=”gender” value="Female">Female<br>
</form>

I meant the whole page's code. tks.

<!doctype html>
<html lang=”en”>
<head>
<meta charset=”utf-8”>
<title>My page</title>
</head>

<body>

<form action=”#” method=”POST” name=”my_form”>
<input type=”text” name=”username”><br>
<input type=”password” name=”password”><br>
<input type=”radio” name=”gender” value="Male">Male<br>
<input type=”radio” name=”gender” value="Female">Female<br>
</form>

</body>
</html>

No worries Jack, could please put my previous answer as "Best Answer" ? Appreciate. :)