This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// watch for changes to motivations select | |
$('#motivations').change(function() { | |
var selected = []; // create an array to hold all currently selected motivations | |
// loop through each available motivation | |
$('#motivations option').each(function() { | |
// if it's selected, add it to the array above | |
if (this.selected) { | |
selected.push(this.value); | |
} |