With this I add a row to my table this row contains data and buttons. But the buttons stop working I have to reload the page for them to work.
How do I make them work without reloading the page after adding with append
$("tbody#agregarusuario").append('<tr><td><input id="obtenerid" type="number" value="'+obj.id_usuario+'" hidden>'+obj.nombres+'</td><td>'+obj.apellidos+'</td><td>'+obj.correo+'</td><td>'+obj.id_tipo_usuario+'</td><td>'+obj.habilitado+'</td><td><a class="waves-effect waves-light btn modal-trigger" href="#modal'+obj.id_usuario+'" style="border-radius: 34px;height: 50px;"><i class="material-icons left" style="margin-right: 0px;position: relative;top: 6px;">edit</i></a></td><td><div id="eliminarusuarios" name="btn_eliminar" class="waves-effect waves-light btn" style="border-radius: 34px;height: 50px;"><i class="material-icons left" style="margin-right: 0px;position: relative;top: 6px;">close</i></div></td>');
use the on method to assign the events example: