JQUERY根据值将input控件选中!

<select>:

$('#country').find("option[value = " + data.country + "]").attr('selected', true);

<intpu type='check'>:

$('input[name=type][value = ' + data.type + ']').attr('checked', 'true');

原文地址:https://www.cnblogs.com/kingfly/p/3593201.html