Skip to content

Instantly share code, notes, and snippets.

@kmallea
Created August 9, 2012 14:05
Show Gist options
  • Save kmallea/3304482 to your computer and use it in GitHub Desktop.
Save kmallea/3304482 to your computer and use it in GitHub Desktop.
Getting all contests
$('.contestsBtn').click(function(){
$('body').wm_votigo.getAllContests(function(d){
// these are the contests results. Do something.
// lets loop through all the contests in the results
$('.contestResults').empty().append('<h3>Get All Contests Results</h3>');
$(d.Contests).each(function(){
console.log(this)
$('.contestResults').append('Contest Name: ' + this.Contest.contestName + ' | Contest ID: ' + this.Contest.contestId + '<br />');
});
});
})
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment