-
Notifications
You must be signed in to change notification settings - Fork 0
/
script.js
24 lines (20 loc) · 852 Bytes
/
script.js
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
function addRecommendation() {
// Show the popup dialog box
document.getElementById('popup').classList.remove('hidden');
}
function submitRecommendation(event) {
event.preventDefault();
// Hide the form and show a confirmation message
document.getElementById('recommendationForm').classList.add('hidden');
document.getElementById('confirmationMessage').classList.remove('hidden');
// Close the popup after a short delay
setTimeout(() => {
document.getElementById('popup').classList.add('hidden');
document.getElementById('recommendationForm').classList.remove('hidden');
document.getElementById('confirmationMessage').classList.add('hidden');
}, 2000);
}
function closePopup() {
// Close the popup
document.getElementById('popup').classList.add('hidden');
}