I would like to add a custom id tag e.g. id = keys[key][each]as part of the html that's being appended to the new_resumes class e.g. I would like
<div class = "filtered_results" id = keys[key][each] ...
instead with the code below - when I use the attr or prop tag it adds an id to the new resumes class. I appreciate my code is not the greatest.
for (var key in keys) {
$(".new_resumes").append("<div class='filtered_results' style='color:white; background-color:red; text-align:center; height:20px; line-height: 20px'>" + key + "</div>");
for (var each in keys[key]) {
$(".new_resumes").append("<div class='filtered_results' style ='height:60px; text-align:center; height:60px; line-height: 60px;'>" + keys[key][each][0] + "</div>").prop('id',keys[key][each][0]);