$('#anc').empty();
var html = "";
$.each(json.re, function(i, relevant) {
html += "<tr>";
html += "<td><input type='hidden' id='rBh"+i +"' value='"+re.id+"'/></td>";
html += "<td class='p'><input type='text' id='Position"+i+ "' value='" + re.Position + "'/></td>";
html += "<td class='n' ><input type='text' id='Name"+i +"' value='" + re.Name + "'/></td>";
html += "<td class='t'><input type='text' id='Phone"+i +"' value='" + re.Phone + "'/></td>";
html += "<td class='m'><i class='mod' onclick='updateRe(\""+re.id+"\","+i+")'></i></td>";
html += "<td class='del' ><i class='del'></i></td>";
html += "</tr>";
$('#r').html(html);
});
转载于:https://my.oschina.net/yuhangyes/blog/751845