Welcome to the Treehouse Community
The Treehouse Community is a meeting place for developers, designers, and programmers of all backgrounds and skill levels to get support. Collaborate here on code errors or bugs that you need feedback on, or asking for an extra set of eyes on your latest project. Join thousands of Treehouse students and alumni in the community today. (Note: Only Treehouse students can comment or ask questions, but non-students are welcome to browse our conversations.)
Looking to learn something new?
Treehouse offers a seven day free trial for new students. Get access to thousands of hours of content and a supportive community. Start your free trial today.

Maarten van Essen
869 PointsSelect not appending
somehow my select is not appending. below is my code
var $select = $('<select></select>'); $("#menu").append($select);
Thanks.

Maarten van Essen
869 PointsPerhaps it has to do with my browser, because I copied and pasted the code form the downloaded material, and it still doesn't work

Maarten van Essen
869 PointsPerhaps it is appending, but I can't see it?
1 Answer

Jonathan Grieve
Treehouse Moderator 90,705 PointsHi Maarten,
I'm guessing here but is it that you need to declare your select HTML tags in a ..html() method?
So
var $select = $("<select></select>").html();
$("#menu").append($select);

Maarten van Essen
869 PointsThanks. Best answer so far ;-) . However still not working. Any other ideas?
Maarten van Essen
869 PointsMaarten van Essen
869 PointsWell copying and pasting isn't going well either...but I think I've mastered the markdown now.
here is the code once more:
What am I doing wrong?