I am trying to create a webpage that has links in a table which are linked to modals that pop up when they are pressed. However these links are appended using Jquery
$("table").append('<tr><td><a href="#exampleModal" data-bs-toggle="modal" data-bs-target="#exampleModal">' + ID +"</a></td><td>" + lastName + "</td><td>"
+ firstName + "</td> <td>" + Course + "</td><td>" + Average + "</td></tr>");
when they are first added into the table, the table and link modals are fine, but when the page is reloaded, the appended code loses some of its text
from:
to:
is there someway to fix this? My first initial thought is to overwrite the previous page's html to the current's but I think this is pretty inefficient and im sure there are more efficient ways to do this functionality.

