I am trying to show only two row. Right now there are four rows displayed. I want to show only two and hide two. And add a button to show rest two when clicked. I am new in front end. Can someone help me in this?
$.each(data, function(i, k) {
bind += '<div class="first">';
bind += '<div class="second">';
bind += '<table>';
bind += '<tr><th>Id</th>' + '<td>' + k.id + '</td></tr>';
bind += '<tr><th> Name</th>' + '<td>' + k.name + '</td></tr>';
bind += '<tr><th>Addresss</th>' + '<td>' + k.address + '</td></tr>';
bind += '<tr><th>Phone</th>' + '<td>' + k.phone + '</td></tr>';
bind += '</table></div></div>';
});