Created
January 24, 2011 18:01
-
-
Save robotlolita/793618 to your computer and use it in GitHub Desktop.
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
function contains(obj, value) { | |
return obj && obj.indexOf(value) != -1 | |
} | |
var checked = contains(sd_o, sd[i].id) // must be false or null to disable | |
var formElm = new Element('input', {'type': 'checkbox' | |
,'name': 'sideDish[]' | |
,'id': 'sideDish_' + sd[i].id | |
,'value': sd[i].id | |
,'checked': checked}) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment