<a href="#" data-user-name="user1" class="delete-user">delete</span></a>
   <a href="#" data-user-name="user2" class="delete-user">delete</span></a>
   <a href="#" data-user-name="user3" class="delete-user">delete</span></a>
   <script>
        $(document).ready(function () {
            $('a.delete-user').each(function (i) {
                var data = $(this).data('user-name');
                $(this).on("click", { x: i }, function (event) {
                    return confirm ("Bude odstraněn uživatel " + data + ". Pokračovat?");
                });
            });
        });
    </script>

 

Vlastimil Pošmura, 2018