Skip to content

Instantly share code, notes, and snippets.

@foxxtrot
Created July 17, 2009 17:18
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save foxxtrot/149178 to your computer and use it in GitHub Desktop.
Save foxxtrot/149178 to your computer and use it in GitHub Desktop.
YUI().use('node','collection', function(Y) {
buildSelectList_MR = function(selectBox) {
return Y.Array.reduce(
Y.NodeList.getDOMNodes(selectBox.get('options')),
"",
function(list, value) {
if (value.selected) {
if (list !== "") { list += ","; }
list += value.value;
}
return list;
});
}
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment