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
varis darasirikul
10,832 PointsTroubles with jquery Challenge task
Select all inputs and on the 'keydown' event select 'this' and then show the next element.
$(".hint").hide();
$("input").keydown(function()
{
$('this').next().show();
});
it doesnΒ΄t work. and i don't know what wrong? and this is link to a Challenge task http://teamtreehouse.com/library/build-an-interactive-website/form-validation-and-manipulation/text-input-events
5 Answers
Kevin Korte
28,149 PointsYou do not put $(this) in quotes. (Edited this answer for correct terminology).
Bailey Scroggins
8,758 PointsI had put this in quotes, too. Instead this is in parenthesis, but not in quotes. $(this)
Kevin Korte
28,149 PointsMy apologies. Parenthesis : good. Quotes : bad. I meant quotes.
Bailey Scroggins
8,758 PointsI understood what you meant, but also know how confused I have been on some of these challenges. I was just clarifying. Cheers!
Kevin Korte
28,149 PointsI'm glad you did! That could have been easily confusing to somebody. Thanks for catching that! :)
varis darasirikul
10,832 PointsI got it. thank you for every one.