-
Notifications
You must be signed in to change notification settings - Fork 3
/
delete.html
101 lines (89 loc) · 2.56 KB
/
delete.html
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
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
<!DOCTYPE html>
<html lang="en">
<head>
<meta charset="UTF-8">
<meta name="viewport" content="width=device-width, initial-scale=1.0">
<title>Delete Book</title>
<link href="https://fonts.googleapis.com/css2?family=Roboto:wght@400;700&display=swap" rel="stylesheet">
<style>
body {
font-family: 'Roboto', sans-serif;
background-color: #121212;
color: #E0E0E0;
margin: 0;
padding: 20px;
}
.container {
max-width: 500px;
margin: 0 auto;
padding: 50px;
background-color: #1E1E1E;
border-radius: 8px;
box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
text-align: center;
}
.details {
margin-bottom: 20px;
text-align: left;
}
button {
padding: 10px 20px;
border: none;
border-radius: 4px;
cursor: pointer;
font-weight: bold;
margin: 5px;
}
button:hover {
transform: scale(1.05);
transition: transform 0.2s ease;
opacity: 0.6;
}
.delete-btn {
background-color: #CF6679;
color: #121212;
}
.cancel-btn {
background-color: #03DAC5;
color: #121212;
}
input, textarea, select {
width: 100%;
padding: 10px;
margin-bottom: 10px;
border: 1px solid #444;
border-radius: 4px;
background-color: #2A2A2A;
color: #E0E0E0;
}
</style>
</head>
<body>
<div class="container">
<h1>Delete Book</h1>
<form id="delete-form">
<label for="title">Book Title:</label>
<input type="text" id="title" name="title" placeholder="Enter book title" required>
<label for="author">Author:</label>
<input type="text" id="author" name="author" placeholder="Enter author name" required>
<label for="isbn"> ISBN:</label>
<input type="text" id="isbn" name="isbn" placeholder="Enter ISBN number" required>
<p>Are you sure you want to delete this book?</p>
<button class="delete-btn" type="submit">Delete</button>
<button class="cancel-btn" type="button" onclick="window.history.back()">Cancel</button>
</form>
</div>
<script>
document.getElementById('delete-form').addEventListener('submit', function(event) {
// Prevent the default form submission
event.preventDefault();
// Show us confirmation pop-up
if (confirm("Are you sure you want to delete this book? This action cannot be undone.")) {
alert("Book deleted successfully!");
// Move us to book management page
window.location.href = "management.html";
}
});
</script>
</body>
</html>