I have a checkboxlist as follows
and this is the js to bind data from database.
function BindSpecialityType() {
$.ajax({
type: "POST",
url: "MRRegistration.aspx/GetSpeciality",
data: {},
contentType: "application/json; charset=utf-8",
dataType: "json",
success: function (response) {
var objdata = $.parseJSON(response.d);
BindSpecialityCheckBoxList('chkbxSpeciality', objdata);
}
});
}
function BindSpecialityCheckBoxList(target, data) {
var table = $('
');
var counter = 0;
$(data).each(function () {
table.append($(' ').append($(' ').append($('').attr({
type: 'checkbox', name: 'chklistitem', value: this.SPECIALITYID , id: target + counter
})).append(
$('
for: 'chklistitem' + counter++
}).text(this.SPECIALITYNAME ))));
});
}
but i am not able to bind. Please help

Manas MohapatraRank #182 · 13.2K reputationPosted Sep 13, 2017, 10:29 PM EDT
Midhun TpRank #388 · 6.5K reputationPosted Sep 14, 2017, 12:49 AM EDT