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

JavaScript

tree house badges jquery script help

So this is the fiddle It have some straight-forward setup.

http://jsfiddle.net/ebinnion/GHm4m/

Im not the author of the script but i think eric binnion is.

I have edited the username to mine, but it still wont show up.

6 Answers

J.T. Gralka
J.T. Gralka
20,126 Points

I'm not sure what you're asking. The script seems to work fine for me. Is it possible that "ericbinnion" is not the user's username? When I change the variable's value to "patrikchristoffersson" it shows all of your badges. When I input an invalid username, nothing shows up (as well it shouldn't).

@J.T when i use the code on my current website im working on - it wont show up. just transparent boxes that move according to the css.

J.T. Gralka
J.T. Gralka
20,126 Points

It's hard to say what your issue is. Do you have a URL to the page on which you're trying to use this code? It's possible you're not including jQuery in your project, but it's tough to say without knowing what your page source looks like.

@J.T sec, im uploading the code to my webserver as we speak so you can have a look at it!

Never mind that, i got it to work now. Time to earn more badges.

Thanks for taking the time to answer my question.