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

WordPress

Mark Flavin
Mark Flavin
10,199 Points

Wordpress Badges Plugin

This version will pull in your badges via your profile JSON and automatically add each badge to your sidebar.

http://wordpress.org/extend/plugins/team-treehouse-badges/

12 Answers

This is great, Mark! I'm sure lots of our members will benefit from this plugin.

Thanks for sharing!

Thanks for sharing this plugin in the forum Mark! As Micah said our members will love it! :)

Mark Flavin
Mark Flavin
10,199 Points

Thank Micah and Faye :)

I also just patched it to version 1.2 which address some issues with JS and CSS files not showing up on some versions of wordpress as well an issue with the JS file grabbing user profile data.

Mark, if I wanted the less verbose descriptions on hover, just back to where this project forked on GitHub and just remove those lines that grab the description from Treehouse?

How cool is that - loving the work Mark

Mark Flavin
Mark Flavin
10,199 Points

@John you have a few options:

  • Modify the plugin ( the js file )
  • Use jQuery to select all the img and trim the attribute
  • Wait till this evening (or tomorrow at the latest) and I will add a checkbox to disable the description :)
Mark Flavin
Mark Flavin
10,199 Points

So I just took a look at the Treehouse JSON file and they do not have the full description in it.

Before I commit the code just looking for a bit of feedback:

If we want to add back the full description I can make it pull from the original YQL query but there will be a performance hit. This would be an option based on the user checking a box in the widget panel.

Question for ya'll is do you think have the extended description is worth the performance hit and if so do you think a checkbox is the best option for configuration.

The performance hit isn't necessarily worth it to me for the extended description. It already takes a second to load the badges for me. A checkbox is a great way to go. I thank you, sir, for putting out such a great plug-in.

You're a star Mark :)

Mark Flavin
Mark Flavin
10,199 Points

Thanks Chris I am glad the plugin is useful!

Is there a version of the plugin that's separate from Wordpress? Would love to use it within a Node.js or Rails 4...

Mark Flavin
Mark Flavin
10,199 Points

Kevin Lozandier

The original widget was built from the following JSFiddle feel free to fork and improve.

http://jsfiddle.net/psyne/spHxu/

James Barnett
James Barnett
39,199 Points

Mark Flavin - Speaking of forks I made this a while back, it's based on your & Riley's code.

http://codepen.io/jamesbarnett/pen/fcugz

James Barnett: Thanks for the information; thank you @Mark Flavin for your original contribution as well.