Here is my fiddle: http://jsfiddle.net/SmWhq/50/
A row gets appended like so:
var tr = $("<tr>");
tr.append($("<td>").text(name.first));
tr.append($("<td>").text(name.last));
tr.append($("<td>").text(name.username));
var cell = "<td class=\"table-action-hide\"><a href=\"#\" class=\"delete-row\" style=\"opacity: 1\"><i class=\"fa fa-trash-o\"></i></a></td>";
tr.append(cell);
//div=tr.append($("<td>").addClass("table-action-hide"));
//div.innerHTML=cell;
tbody.append(tr);
On adding a row, the data gets added to the table but the fa-trash icon is either not visible (with opacity set to 0) or always visible (with opacity set to 1) on the added row.
Also the delete function does not get called on clicking the 'fa-trash' icon.
What is wrong with the attached code ?