I have this code here and I'm trying to read the ids of all the elements of the selected class, but the result is always undefined. Any suggestions?
$(".notification_new").click(() => {
let id = $(this).attr('id');
alert(id);
$.post("/update.php", {
reqType: "changeNotificationStatus",
notifId: id,
dataType: "json"
}, response => {
alert(response);
)
})
});