-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy path_deleteModal.php
More file actions
37 lines (36 loc) · 1.37 KB
/
Copy path_deleteModal.php
File metadata and controls
37 lines (36 loc) · 1.37 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
<!-- Modal -->
<div class="modal fade" id="deleteModal" tabindex="-1" aria-labelledby="deleteModal" aria-hidden="true">
<div class="modal-dialog">
<div class="modal-content">
<div class="modal-header">
<h5 class="modal-title" id="deleteModalLabel">Deletar Task</h5>
<button type="button" class="btn-close" data-dismiss="modal" aria-label="Close">
</button>
</div>
<div class="modal-body">
Are you sure you want to delete this task?
</div>
<div class="modal-footer">
<button type="button" class="btn btn-secondary" data-dismiss="modal">
Cancel
</button>
<form action="/tasks/delete.php" class="formDeleteTask" method="POST">
<input type="hidden" name="id" id="id" value="">
<button class="btn btn-outline-danger mx-1">
Delete
</button>
</form>
</div>
</div>
</div>
</div>
<script type="text/javascript">
// Delete Modal script
$(function () {
$(".deleteButton").click(function () {
var my_id_value = $(this).data('id');
console.log(my_id_value);
$(".formDeleteTask #id").val(my_id_value);
})
});
</script>